pgsql: Avoid core dump after getpwuid_r failure.

Started by Tom Lanealmost 2 years ago1 messagescomitters
Jump to latest
#1Tom Lane
tgl@sss.pgh.pa.us

Avoid core dump after getpwuid_r failure.

Looking up a nonexistent user ID would lead to a null pointer
dereference. That's unlikely to happen here, but perhaps
not impossible.

Thinko in commit 4d5111b3f, noticed by Coverity.

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/2e62fa62d6745ba3bcb0a517d002aff1f3cdefb7

Modified Files
--------------
src/interfaces/libpq/fe-auth.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)