diff options
author | Peter Eisentraut | 2012-01-16 18:08:33 +0000 |
---|---|---|
committer | Peter Eisentraut | 2012-01-16 18:08:33 +0000 |
commit | 1b9f774090d58a950ef0535b51bc377ab62b795c (patch) | |
tree | 8c4232a7876fb64bd6109fe0602d0683290720bb /src/bin | |
parent | 1575fbcb795fc331f46588b4520c4bca7e854d5c (diff) |
psql: Fix memory leak
The command
\password username
leaked memory.
Diffstat (limited to 'src/bin')
-rw-r--r-- | src/bin/psql/command.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/bin/psql/command.c b/src/bin/psql/command.c index 69fac83cd58..6c3f0aa69d6 100644 --- a/src/bin/psql/command.c +++ b/src/bin/psql/command.c @@ -953,6 +953,9 @@ exec_command(const char *cmd, PQclear(res); PQfreemem(encrypted_password); } + + if (opt0) + free(opt0); } free(pw1); |