Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 424eded

Browse files
committed
Adjust pg_dump tag for relation stats.
Do not use fmtId(), just use dobj->name directly, like for table data.
1 parent c2a50ac commit 424eded

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/bin/pg_dump/pg_dump.c

+1-6
Original file line numberDiff line numberDiff line change
@@ -10490,7 +10490,6 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
1049010490
PGresult *res;
1049110491
PQExpBuffer query;
1049210492
PQExpBuffer out;
10493-
PQExpBuffer tag;
1049410493
DumpId *deps = NULL;
1049510494
int ndeps = 0;
1049610495
char *qualified_name;
@@ -10522,9 +10521,6 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
1052210521
ndeps = dobj->nDeps;
1052310522
}
1052410523

10525-
tag = createPQExpBuffer();
10526-
appendPQExpBufferStr(tag, fmtId(dobj->name));
10527-
1052810524
query = createPQExpBuffer();
1052910525
if (!fout->is_prepared[PREPQUERY_GETATTRIBUTESTATS])
1053010526
{
@@ -10695,7 +10691,7 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
1069510691
PQclear(res);
1069610692

1069710693
ArchiveEntry(fout, nilCatalogId, createDumpId(),
10698-
ARCHIVE_OPTS(.tag = tag->data,
10694+
ARCHIVE_OPTS(.tag = dobj->name,
1069910695
.namespace = dobj->namespace->dobj.name,
1070010696
.description = "STATISTICS DATA",
1070110697
.section = rsinfo->postponed_def ?
@@ -10707,7 +10703,6 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
1070710703
free(qualified_name);
1070810704
destroyPQExpBuffer(out);
1070910705
destroyPQExpBuffer(query);
10710-
destroyPQExpBuffer(tag);
1071110706
}
1071210707

1071310708
/*

0 commit comments

Comments
 (0)