Return-Path: owner-postman Delivery-Date: Tue, 10 May 94 06:35:35 -0700 Return-Path: owner-postman Received: from localhost (localhost [127.0.0.1]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with SMTP id AAA05811 for postgres-redist; Tue, 10 May 1994 00:47:31 -0700 Resent-From: POSTGRES mailing list Resent-Message-Id: <199405100747.AAA05811@nobozo.CS.Berkeley.EDU> X-Authentication-Warning: nobozo.CS.Berkeley.EDU: Host localhost didn't use HELO protocol Sender: owner-postman@postgres.Berkeley.EDU X-Return-Path: owner-postman Received: from mailgzrz.TU-Berlin.DE (mailgzrz.TU-Berlin.DE [130.149.4.10]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with SMTP id AAA05743 for ; Tue, 10 May 1994 00:41:13 -0700 Received: from marie.physik.TU-Berlin.DE by mailgzrz.TU-Berlin.DE (5.65c/ZRZ-MX) for id AA04307; Tue, 10 May 1994 09:38:58 +0200 Received: by marie.physik.tu-berlin.de (5.0/SMI-SVR4) id AA11199; Tue, 10 May 1994 09:38:34 --100 From: wpp@marie.physik.tu-berlin.de (Kai Petzke) Message-Id: <9405100738.AA11199@marie.physik.tu-berlin.de> Subject: Re: [frank@odf.UCSD.EDU: Re: destroyuser] To: leland@straylight.tamu.edu (Leland Ellis) Date: Tue, 10 May 1994 09:38:32 +0200 (MET DST) Cc: postgres@postgres.Berkeley.EDU In-Reply-To: <9405091647.AA09488@straylight.tamu.edu> from "Leland Ellis" at May 9, 94 11:47:16 am X-Mailer: ELM [version 2.4 PL23] Content-Type: text Content-Length: 1431 Resent-To: postgres-redist@postgres.Berkeley.EDU Resent-Date: Tue, 10 May 94 00:47:31 -0700 Resent-XMts: smtp > This is a bug (at least for Sun sh). A simple fix is included (from the > top of your Postgres distribution, patch -p0 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. ===============================================================================