pg_dump: Remove trivial usage of PQExpBuffer - Mailing list pgsql-hackers

From Corey Huinker
Subject pg_dump: Remove trivial usage of PQExpBuffer
Date
Msg-id CADkLM=dVdskX03Mtb-eWpiWCfkKcenzRim_sauFf3Z5x2uLF2Q@mail.gmail.com
Whole thread Raw
Responses Re: pg_dump: Remove trivial usage of PQExpBuffer
List pgsql-hackers
I've been looking at ways to reorganize and/or clean up pg_dump.c.

One thing I have noticed is the usage of PQExpBuffer in situations where the query has no optional parts and no string interpolation.

Attached is a patch to replace those usages with the string literal itself. There are still a few cases where a buffer is used for a trivial query and then reset and reused for a more complicated query generation. In those cases, I did not make the change so as to keep this patch simple.
Attachment

pgsql-hackers by date:

Previous
From: Mihail Nikalayeu
Date:
Subject: Re: Revisiting {CREATE INDEX, REINDEX} CONCURRENTLY improvements
Next
From: Andres Freund
Date:
Subject: Re: [PATCH] Fix ARM64/MSVC atomic memory ordering issues on Win11 by adding explicit DMB ?barriers