Fix up the PQconnectionUsedPassword mess: create a separate
Tom Lane <tgl@sss.pgh.pa.us>
Fix up the PQconnectionUsedPassword mess: create a separate PQconnectionNeedsPassword function that tells the right thing for whether to prompt for a password, and improve PQconnectionUsedPassword so that it checks whether the password used by the connection was actually supplied as a connection argument, instead of coming from environment or a password file. Per bug report from Mark Cave-Ayland and subsequent discussion.
Files
| Path | Change | +/− |
|---|---|---|
| doc/src/sgml/libpq.sgml | modified | +27 −5 |
| doc/src/sgml/release.sgml | modified | +17 −3 |
| src/bin/pg_ctl/pg_ctl.c | modified | +2 −2 |
| src/bin/pg_dump/pg_backup_db.c | modified | +3 −3 |
| src/bin/pg_dump/pg_dumpall.c | modified | +2 −2 |
| src/bin/psql/command.c | modified | +2 −2 |
| src/bin/psql/startup.c | modified | +2 −2 |
| src/bin/scripts/common.c | modified | +2 −2 |
| src/interfaces/libpq/exports.txt | modified | +2 −1 |
| src/interfaces/libpq/fe-auth.c | modified | +3 −2 |
| src/interfaces/libpq/fe-connect.c | modified | +34 −13 |
| src/interfaces/libpq/libpq-fe.h | modified | +3 −2 |
| src/interfaces/libpq/libpq-int.h | modified | +3 −2 |