diff options
author | Stephen Frost <sfrost@snowman.net> | 2013-07-14 17:44:29 -0400 |
---|---|---|
committer | Stephen Frost <sfrost@snowman.net> | 2013-07-14 17:44:29 -0400 |
commit | 5461d36b5b7d99e237b2f63a7975e6430727cb0b (patch) | |
tree | 95658bf90ee85b5ebaeb9dc9fcd50d2390e54ae3 | |
parent | cec62efd0e551a56635b47ea4185ec27a6840de7 (diff) | |
download | postgresql-5461d36b5b7d99e237b2f63a7975e6430727cb0b.tar.gz postgresql-5461d36b5b7d99e237b2f63a7975e6430727cb0b.zip |
Fix resource leak in initdb -X option
When creating the symlink for the xlog directory, free the string
which stores the link location. Not really an issue but it doesn't
hurt to be good about this- prior cleanups have fixed similar
issues.
Leak found by the Coverity scanner.
Not back-patching as I don't see it being worth the code churn.
-rw-r--r-- | src/bin/initdb/initdb.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c index 5fc7291ff69..f66f5302883 100644 --- a/src/bin/initdb/initdb.c +++ b/src/bin/initdb/initdb.c @@ -3309,6 +3309,7 @@ create_xlog_symlink(void) fprintf(stderr, _("%s: symlinks are not supported on this platform")); exit_nicely(); #endif + free(linkloc); } } |