diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2017-03-12 15:57:03 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2017-03-12 15:57:03 -0400 |
commit | 835cc1136745e8cf02d3d0231b5b7c7a543df5df (patch) | |
tree | b72d6e18e5db44c1b05e24073cb3de8adc8cc43d | |
parent | 5d3f7c57ab9c9e2f074ad29d619056570fc5c51e (diff) | |
download | postgresql-835cc1136745e8cf02d3d0231b5b7c7a543df5df.tar.gz postgresql-835cc1136745e8cf02d3d0231b5b7c7a543df5df.zip |
Fix typo in initdb's SCRAM password processing.
Noted by Coverity (a rather impressive catch).
Michael Paquier
-rw-r--r-- | src/bin/initdb/initdb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c index 3f836efc20f..da113bd2635 100644 --- a/src/bin/initdb/initdb.c +++ b/src/bin/initdb/initdb.c @@ -2331,7 +2331,7 @@ check_need_password(const char *authmethodlocal, const char *authmethodhost) strcmp(authmethodlocal, "scram") == 0) && (strcmp(authmethodhost, "md5") == 0 || strcmp(authmethodhost, "password") == 0 || - strcmp(authmethodlocal, "scram") == 0) && + strcmp(authmethodhost, "scram") == 0) && !(pwprompt || pwfilename)) { fprintf(stderr, _("%s: must specify a password for the superuser to enable %s authentication\n"), progname, |