Skip to content

Commit b67d83c

Browse files
committed
fix
1 parent 698ace9 commit b67d83c

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/bin/pg_upgrade/info.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -348,8 +348,8 @@ get_non_default_acl_infos(ClusterInfo *cluster)
348348
DbInfo *dbinfo = &cluster->dbarr.dbs[dbnum];
349349
PGconn *conn = connectToServer(cluster, dbinfo->db_name);
350350
PGresult *res;
351-
AclInfo *aclinfos;
352-
AclInfo *curr;
351+
AclInfo *aclinfos = NULL;
352+
AclInfo *curr = NULL;
353353
int nacls = 0,
354354
size_acls = 8;
355355
int aclnum = 0;
@@ -711,6 +711,7 @@ free_db_and_rel_infos(DbInfoArr *db_arr)
711711
for (dbnum = 0; dbnum < db_arr->ndbs; dbnum++)
712712
{
713713
free_rel_infos(&db_arr->dbs[dbnum].rel_arr);
714+
714715
if (&db_arr->dbs[dbnum].non_def_acl_arr.nacls > 0)
715716
free_acl_infos(&db_arr->dbs[dbnum].non_def_acl_arr);
716717
pg_free(db_arr->dbs[dbnum].db_name);
@@ -750,7 +751,9 @@ free_acl_infos(AclInfoArr *acl_arr)
750751
pg_free(acl_arr->aclinfos[aclnum].obj_ident);
751752
pg_free(acl_arr->aclinfos[aclnum].role_names);
752753
}
754+
753755
pg_free(acl_arr->aclinfos);
756+
acl_arr->aclinfos = NULL;
754757
acl_arr->nacls = 0;
755758
pg_log(PG_REPORT, "free_acl_infos 2 %d\n", acl_arr->nacls);
756759
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy