agora inbox for postgres@postgres.berkeley.edu
help / color / mirror / Atom feedFrom: Kai Petzke <wpp@marie.physik.tu-berlin.de>
To: Leland Ellis <leland@straylight.tamu.edu>
Cc: postgres@postgres.Berkeley.EDU
Subject: Re: [frank@odf.UCSD.EDU: Re: destroyuser]
Date: Tue, 10 May 1994 09:38:32 +0200 (MET DST)
Message-ID: <9405100738.AA11199@marie.physik.tu-berlin.de> (raw)
In-Reply-To: <9405091647.AA09488@straylight.tamu.edu>
> This is a bug (at least for Sun sh). A simple fix is included (from the
> top of your Postgres distribution, patch -p0 <thisPatch, then from your
> src directory, bmake all install).
GNU Bourne Again Shell (bash) has the same problem, too. For a fix,
I changed the function, which reads integers, to be less pedantic
about trailing blanks. Apply this patch from the main postgres dir,
then do a "bmake install" in ~postgres/src/backend.
Kai
*** src/backend/utils/adt/numutils.c.old Sat Apr 2 00:44:23 1994
--- src/backend/utils/adt/numutils.c Wed Apr 20 10:50:26 1994
***************
*** 32,40 ****
l = strtol(s, &badp, 10);
if (errno) /* strtol must set ERANGE */
elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
! if (badp && *badp && (*badp != c))
! elog(WARN, "pg_atoi: error in \"%s\": can\'t parse \"%s\"", s, badp);
switch (size) {
case sizeof(int32):
#ifdef PORTNAME_alpha
--- 32,48 ----
l = strtol(s, &badp, 10);
if (errno) /* strtol must set ERANGE */
elog(WARN, "pg_atoi: error reading \"%s\": %m", s);
! /*
! * ignore trailing blanks!
! */
! if (badp) {
! while((*badp == ' ' || *badp == '\n' || *badp == '\t') && *badp != c)
! badp++;
+ if(*badp && (*badp != c))
+ elog(WARN, "pg_atoi: error in \"%s\": can\'t parse \"%s\"", s, badp);
+ }
+
switch (size) {
case sizeof(int32):
#ifdef PORTNAME_alpha
===============================================================================
To add/remove yourself from the POSTGRES mailing list: send mail with
the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU"
If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and
a human will deal with it. DO NOT post to the "postgres" mailing list.
===============================================================================
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: postgres@postgres.berkeley.edu
Cc: wpp@marie.physik.tu-berlin.de, leland@straylight.tamu.edu
Subject: Re: [frank@odf.UCSD.EDU: Re: destroyuser]
In-Reply-To: <9405100738.AA11199@marie.physik.tu-berlin.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox