Re: Check for integer overflow in datetime functions - Mailing list pgsql-patches

From Neil Conway
Subject Re: Check for integer overflow in datetime functions
Date
Msg-id 1133424721.10985.22.camel@localhost.localdomain
Whole thread Raw
In response to Check for integer overflow in datetime functions  (Michael Fuhr <mike@fuhr.org>)
Responses Re: Check for integer overflow in datetime functions  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-patches
On Wed, 2005-11-30 at 19:36 -0700, Michael Fuhr wrote:
> Check integer conversion for overflow in datetime functions.

It seems a bit laborious to always manually set errno to zero before
invoking strtol() (both in the places added by the patch, and all the
places that already did that). While it's only a minor notational
improvement, I wonder if it would be worth adding a pg_strtol() that did
the errno assignment so that each call-site wouldn't need to worry about
it?

-Neil



pgsql-patches by date:

Previous
From: Tatsuo Ishii
Date:
Subject: Re: A couple of proposed pgbench changes
Next
From: Alvaro Herrera
Date:
Subject: Re: aclchk.c refactor