On 2021-Mar-05, tsunakawa.ta...@fujitsu.com wrote: > From: Tom Lane <t...@sss.pgh.pa.us> > > But I think passing the message start address explicitly might be > > better than having it understand the buffering behavior in enough > > detail to know where to find the message. Part of the point here > > (IMO) is to decouple the tracing logic from the core libpq logic, in > > hopes of not having common-mode bugs. > > Ouch, you're perfectly right. Then let's make the signature: > > void pqLogMessage(PGconn *conn, const char *message, bool toServer);
Yeah, looks good! I agree that going this route will result in more trustworthy trace output. -- Álvaro Herrera 39°49'30"S 73°17'W