aboutsummaryrefslogtreecommitdiff
path: root/src/bin/pg_dump/pg_dump.c
diff options
context:
space:
mode:
authorDavid Rowley <drowley@postgresql.org>2025-04-17 11:37:55 +1200
committerDavid Rowley <drowley@postgresql.org>2025-04-17 11:37:55 +1200
commit3fae25cbb35aa885c411fb51f55a64bb80dc5844 (patch)
tree5e4438e2c2bb37d559ef2cc47e16886615a3f17b /src/bin/pg_dump/pg_dump.c
parentf3281f9f9395099724b55ddc52991a92795c6068 (diff)
downloadpostgresql-3fae25cbb35aa885c411fb51f55a64bb80dc5844.tar.gz
postgresql-3fae25cbb35aa885c411fb51f55a64bb80dc5844.zip
Fixup various new-to-v18 usages of appendPQExpBuffer
Use appendPQExpBufferStr when there are no parameters and appendPQExpBufferChar when the string length is 1. Author: David Rowley <drowleyml@gmail.com> Discussion: https://postgr.es/m/CAApHDvoARMvPeXTTC0HnpARBHn-WgVstc8XFCyMGOzvgu_1HvQ@mail.gmail.com
Diffstat (limited to 'src/bin/pg_dump/pg_dump.c')
-rw-r--r--src/bin/pg_dump/pg_dump.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c
index b158d96a831..8ef9c6a021a 100644
--- a/src/bin/pg_dump/pg_dump.c
+++ b/src/bin/pg_dump/pg_dump.c
@@ -9751,7 +9751,7 @@ determineNotNullFlags(Archive *fout, PGresult *res, int r,
{
*invalidnotnulloids = createPQExpBuffer();
appendPQExpBufferChar(*invalidnotnulloids, '{');
- appendPQExpBuffer(*invalidnotnulloids, "%s", constroid);
+ appendPQExpBufferStr(*invalidnotnulloids, constroid);
}
else
appendPQExpBuffer(*invalidnotnulloids, ",%s", constroid);
@@ -10978,7 +10978,7 @@ dumpRelationStats_dumper(Archive *fout, const void *userArg, const TocEntry *te)
*/
if (rsinfo->nindAttNames == 0)
{
- appendPQExpBuffer(out, ",\n\t'attname', ");
+ appendPQExpBufferStr(out, ",\n\t'attname', ");
appendStringLiteralAH(out, attname, fout);
}
else