Re: Add error-checking to timestamp_recv - Mailing list pgsql-patches

From Tom Lane
Subject Re: Add error-checking to timestamp_recv
Date
Msg-id 3357.1085077071@sss.pgh.pa.us
Whole thread Raw
In response to Re: Add error-checking to timestamp_recv  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Add error-checking to timestamp_recv
List pgsql-patches
I wrote:
> In general we do check incoming binary values to ensure minimal
> validity.  I think when I did timestamp_recv I was thinking it was
> just like int8 or float8 (respectively), in that any bit pattern is
> potentially legal; I had forgotten about the range restrictions.

> I haven't looked at the details of Stephen's patch (and can't till the
> archives site comes back up) but the idea is probably sound.

Having looked at it, I don't like the patch as-is; it misses
timestamptz_recv and doesn't handle the boundary condition
correctly for the HasCTZSet case.  However the details of the latter
are likely to change completely once we finish adopting src/timezone.
I'll make a note to do something with this issue after the TZ patch
is in.

            regards, tom lane

pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: Add error-checking to timestamp_recv
Next
From: Jorge Pereira
Date:
Subject: Disabling triggers / constraints