Don't try to free pgpassfile since it's a stack variable.
authorMagnus Hagander <[email protected]>
Tue, 9 Oct 2007 15:03:31 +0000 (15:03 +0000)
committerMagnus Hagander <[email protected]>
Tue, 9 Oct 2007 15:03:31 +0000 (15:03 +0000)
Martin Pitt

src/interfaces/libpq/fe-connect.c

index a50bb33a5b1dc58c1d7f8299f0042ea58584ecb6..4e7e127978db1914ecf64ed36de310b25e1d238f 100644 (file)
@@ -3620,7 +3620,6 @@ PasswordFromFile(char *hostname, char *port, char *dbname, char *username)
                fprintf(stderr,
                libpq_gettext("WARNING: password file \"%s\" is not a plain file\n"),
                                pgpassfile);
-               free(pgpassfile);
                return NULL;
        }