diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c index d56dcc701ce..a0f7f8e2168 100644 --- a/src/bin/pg_dump/pg_dump.c +++ b/src/bin/pg_dump/pg_dump.c @@ -8161,8 +8161,6 @@ getIndexes(Archive *fout, TableInfo tblinfo[], int numTables) { Oid indrelid = atooid(PQgetvalue(res, j, i_indrelid)); TableInfo *tbinfo = NULL; - char **indAttNames = NULL; - int nindAttNames = 0; int numinds; /* Count rows for this table */ @@ -8196,6 +8194,8 @@ getIndexes(Archive *fout, TableInfo tblinfo[], int numTables) { char contype; char indexkind; + char **indAttNames = NULL; + int nindAttNames = 0; RelStatsInfo *relstats; int32 relpages = atoi(PQgetvalue(res, j, i_relpages)); int32 relallvisible = atoi(PQgetvalue(res, j, i_relallvisible));