BUG #1167: POSIX getpwuid_r 4arg vs 5arg issue

Started by PostgreSQL Bugs Listalmost 22 years ago5 messagesbugs
Jump to latest
#1PostgreSQL Bugs List
pgsql-bugs@postgresql.org

The following bug has been logged online:

Bug reference: 1167
Logged by: James Helm

Email address: jjhelm@att.net

PostgreSQL version: 7.4

Operating system: Solaris 9 Sparc

Description: POSIX getpwuid_r 4arg vs 5arg issue

Details:

I just downloaded the 7.4.3 tarball with timestamp 6/15 00:02, and am still
having issues with threads on a freshly loaded Solaris 9 server. Looks like
maybe the latest Solaris 9 supports the 5 arg version of getpwuid_r? I'm
just going to build without thread safety since I don't really need it for
now, but I thought you'd want to know it was still not 100% fixed.

Thanks.

Jim

gcc -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes
-Wmissing-declarations
-fPIC -I. -I../../../src/include -I/pbengine/postgres/include
-I/pbengine/openssl/include -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS
-DFRONTEND
-DSYSCONFDIR='"/pbengine/postgres/etc"' -c -o thread.o thread.c
thread.c: In function `pqGetpwuid':
thread.c:119: error: too few arguments to function `getpwuid_r'
thread.c:119: warning: assignment makes pointer from integer without a cast
gmake[3]: *** [thread.o] Error 1

Here's my configure:

sh configure \
--prefix=/pbengine/postgres \
--with-includes=/pbengine/postgres/include \
--with-libs=/pbengine/postgres/lib \
--with-perl \
--with-openssl=/pbengine/openssl \
--enable-thread-safety

#2Bruce Momjian
bruce@momjian.us
In reply to: PostgreSQL Bugs List (#1)
Re: BUG #1167: POSIX getpwuid_r 4arg vs 5arg issue

Well, shame you reported it today, rather than a few days before the
release. I added code which should have detected whether your system
uses 4 or 5 args to getpwuid_r, but obviously it didn't work in your
case.

I need to see your config.log's references to getpwuid_r to find the
cause of the failure.

---------------------------------------------------------------------------

PostgreSQL Bugs List wrote:

The following bug has been logged online:

Bug reference: 1167
Logged by: James Helm

Email address: jjhelm@att.net

PostgreSQL version: 7.4

Operating system: Solaris 9 Sparc

Description: POSIX getpwuid_r 4arg vs 5arg issue

Details:

I just downloaded the 7.4.3 tarball with timestamp 6/15 00:02, and am still
having issues with threads on a freshly loaded Solaris 9 server. Looks like
maybe the latest Solaris 9 supports the 5 arg version of getpwuid_r? I'm
just going to build without thread safety since I don't really need it for
now, but I thought you'd want to know it was still not 100% fixed.

Thanks.

Jim

gcc -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes
-Wmissing-declarations
-fPIC -I. -I../../../src/include -I/pbengine/postgres/include
-I/pbengine/openssl/include -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS
-DFRONTEND
-DSYSCONFDIR='"/pbengine/postgres/etc"' -c -o thread.o thread.c
thread.c: In function `pqGetpwuid':
thread.c:119: error: too few arguments to function `getpwuid_r'
thread.c:119: warning: assignment makes pointer from integer without a cast
gmake[3]: *** [thread.o] Error 1

Here's my configure:

sh configure \
--prefix=/pbengine/postgres \
--with-includes=/pbengine/postgres/include \
--with-libs=/pbengine/postgres/lib \
--with-perl \
--with-openssl=/pbengine/openssl \
--enable-thread-safety

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo@postgresql.org)

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073
#3Bruce Momjian
bruce@momjian.us
In reply to: PostgreSQL Bugs List (#1)
Re: BUG #1167: POSIX getpwuid_r 4arg vs 5arg issue

OK, I have fixed this so the configure test happens with the proper
thread flags. Patch attached, and it will be in 7.4.4.

---------------------------------------------------------------------------

PostgreSQL Bugs List wrote:

The following bug has been logged online:

Bug reference: 1167
Logged by: James Helm

Email address: jjhelm@att.net

PostgreSQL version: 7.4

Operating system: Solaris 9 Sparc

Description: POSIX getpwuid_r 4arg vs 5arg issue

Details:

I just downloaded the 7.4.3 tarball with timestamp 6/15 00:02, and am still
having issues with threads on a freshly loaded Solaris 9 server. Looks like
maybe the latest Solaris 9 supports the 5 arg version of getpwuid_r? I'm
just going to build without thread safety since I don't really need it for
now, but I thought you'd want to know it was still not 100% fixed.

Thanks.

Jim

gcc -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes
-Wmissing-declarations
-fPIC -I. -I../../../src/include -I/pbengine/postgres/include
-I/pbengine/openssl/include -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS
-DFRONTEND
-DSYSCONFDIR='"/pbengine/postgres/etc"' -c -o thread.o thread.c
thread.c: In function `pqGetpwuid':
thread.c:119: error: too few arguments to function `getpwuid_r'
thread.c:119: warning: assignment makes pointer from integer without a cast
gmake[3]: *** [thread.o] Error 1

Here's my configure:

sh configure \
--prefix=/pbengine/postgres \
--with-includes=/pbengine/postgres/include \
--with-libs=/pbengine/postgres/lib \
--with-perl \
--with-openssl=/pbengine/openssl \
--enable-thread-safety

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo@postgresql.org)

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

Attachments:

/bjm/difftext/plainDownload+7-4
#4Jim Helm
jjhelm@att.net
In reply to: Bruce Momjian (#3)
Re: BUG #1167: POSIX getpwuid_r 4arg vs 5arg issue

Thanks. I wish I had seen it earlier myself. I've been busy on other
projects and haven't been following the 7.4.X releases. Doesn't hurt me
any, since I was able to just build without thread support, but I
thought it would be good for other to know about it.

Thanks again - for this, and all the work you guys have put into
PostgreSQL.

--Jim

Show quoted text

-----Original Message-----
From: Bruce Momjian [mailto:pgman@candle.pha.pa.us]
Sent: Tuesday, June 15, 2004 8:48 PM
To: James Helm
Cc: pgsql-bugs@postgresql.org
Subject: Re: [BUGS] BUG #1167: POSIX getpwuid_r 4arg vs 5arg issue

OK, I have fixed this so the configure test happens with the proper
thread flags. Patch attached, and it will be in 7.4.4.

--------------------------------------------------------------
-------------

PostgreSQL Bugs List wrote:

The following bug has been logged online:

Bug reference: 1167
Logged by: James Helm

Email address: jjhelm@att.net

PostgreSQL version: 7.4

Operating system: Solaris 9 Sparc

Description: POSIX getpwuid_r 4arg vs 5arg issue

Details:

I just downloaded the 7.4.3 tarball with timestamp 6/15

00:02, and am still

having issues with threads on a freshly loaded Solaris 9

server. Looks like

maybe the latest Solaris 9 supports the 5 arg version of

getpwuid_r? I'm

just going to build without thread safety since I don't

really need it for

now, but I thought you'd want to know it was still not 100% fixed.

Thanks.

Jim

gcc -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes
-Wmissing-declarations
-fPIC -I. -I../../../src/include -I/pbengine/postgres/include
-I/pbengine/openssl/include -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS
-DFRONTEND
-DSYSCONFDIR='"/pbengine/postgres/etc"' -c -o thread.o thread.c
thread.c: In function `pqGetpwuid':
thread.c:119: error: too few arguments to function `getpwuid_r'
thread.c:119: warning: assignment makes pointer from

integer without a cast

gmake[3]: *** [thread.o] Error 1

Here's my configure:

sh configure \
--prefix=/pbengine/postgres \
--with-includes=/pbengine/postgres/include \
--with-libs=/pbengine/postgres/lib \
--with-perl \
--with-openssl=/pbengine/openssl \
--enable-thread-safety

---------------------------(end of

broadcast)---------------------------

TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to

majordomo@postgresql.org)

-- 
Bruce Momjian                        |  http://candle.pha.pa.us
pgman@candle.pha.pa.us               |  (610) 359-1001
+  If your life is a hard drive,     |  13 Roberts Road
+  Christ can be your backup.        |  Newtown Square, 
Pennsylvania 19073
#5Bruce Momjian
bruce@momjian.us
In reply to: Jim Helm (#4)
Re: BUG #1167: POSIX getpwuid_r 4arg vs 5arg issue

Jim Helm wrote:

Thanks. I wish I had seen it earlier myself. I've been busy on other
projects and haven't been following the 7.4.X releases. Doesn't hurt me
any, since I was able to just build without thread support, but I
thought it would be good for other to know about it.

Thanks again - for this, and all the work you guys have put into
PostgreSQL.

CVS had the same bug were we were testing without the thread flags.

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073