fix-api-misuse-pg_amcheck.patch

application/octet-stream

Filename: fix-api-misuse-pg_amcheck.patch
Type: application/octet-stream
Part: 0
Message: Re: Small memory fixes for pg_createsubcriber

Patch

Format: unified
File+
src/bin/pg_amcheck/pg_amcheck.c 1 1
diff --git a/src/bin/pg_amcheck/pg_amcheck.c b/src/bin/pg_amcheck/pg_amcheck.c
index c5ec25be22..dda8b1b8ad 100644
--- a/src/bin/pg_amcheck/pg_amcheck.c
+++ b/src/bin/pg_amcheck/pg_amcheck.c
@@ -560,7 +560,7 @@ main(int argc, char *argv[])
 
 			executeCommand(conn, install_sql, opts.echo);
 			pfree(install_sql);
-			pfree(schema);
+			PQfreemem(schema);
 		}
 
 		/*