|
5 | 5 | * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group |
6 | 6 | * Portions Copyright (c) 1994, Regents of the University of California |
7 | 7 | * |
8 | | - * $PostgreSQL: pgsql/src/bin/scripts/createuser.c,v 1.8 2004/01/01 19:27:15 tgl Exp $ |
| 8 | + * $PostgreSQL: pgsql/src/bin/scripts/createuser.c,v 1.9 2004/01/09 00:15:11 tgl Exp $ |
9 | 9 | * |
10 | 10 | *------------------------------------------------------------------------- |
11 | 11 | */ |
@@ -189,12 +189,12 @@ main(int argc, char *argv[]) |
189 | 189 | printfPQExpBuffer(&sql,"CREATE USER %s",fmtId(newuser)); |
190 | 190 | if (sysid) |
191 | 191 | appendPQExpBuffer(&sql," SYSID %s",sysid); |
192 | | -if (encrypted==+1) |
193 | | -appendPQExpBuffer(&sql," ENCRYPTED"); |
194 | | -if (encrypted==-1) |
195 | | -appendPQExpBuffer(&sql," UNENCRYPTED"); |
196 | 192 | if (newpassword) |
197 | 193 | { |
| 194 | +if (encrypted==+1) |
| 195 | +appendPQExpBuffer(&sql," ENCRYPTED"); |
| 196 | +if (encrypted==-1) |
| 197 | +appendPQExpBuffer(&sql," UNENCRYPTED"); |
198 | 198 | appendPQExpBuffer(&sql," PASSWORD "); |
199 | 199 | appendStringLiteral(&sql,newpassword, false); |
200 | 200 | } |
|