diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2001-08-02 14:39:35 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2001-08-02 14:39:35 +0000 |
commit | d00b272299f1fdccfcca9c8df183f1cfc35cbb54 (patch) | |
tree | eef6b605ffcd35deef4df8a54a8bfca0dd352eb8 /src | |
parent | 49435fb98f6b58617fb65ac2080a0b9d81edc03e (diff) | |
download | postgresql-d00b272299f1fdccfcca9c8df183f1cfc35cbb54.tar.gz postgresql-d00b272299f1fdccfcca9c8df183f1cfc35cbb54.zip |
Even though SO_PEERCRED is probably totally unportable, might as well
declare the getsockopt parameter as ACCEPT_TYPE_ARG3 to be consistent
with our other uses of getsockopt.
Diffstat (limited to 'src')
-rw-r--r-- | src/backend/libpq/hba.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/backend/libpq/hba.c b/src/backend/libpq/hba.c index 4846f8fb5f9..b91427460d2 100644 --- a/src/backend/libpq/hba.c +++ b/src/backend/libpq/hba.c @@ -10,7 +10,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/libpq/hba.c,v 1.60 2001/08/02 14:27:40 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/libpq/hba.c,v 1.61 2001/08/02 14:39:35 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -863,11 +863,10 @@ ident_unix(int sock, char *ident_user) #ifdef SO_PEERCRED /* Linux style: use getsockopt(SO_PEERCRED) */ struct ucred peercred; - socklen_t so_len; + ACCEPT_TYPE_ARG3 so_len = sizeof(peercred); struct passwd *pass; errno = 0; - so_len = sizeof(peercred); if (getsockopt(sock, SOL_SOCKET, SO_PEERCRED, &peercred, &so_len) != 0 || so_len != sizeof(peercred)) { |