From: Tom Lane <tgl@sss.pgh.pa.us>
To: Igor Shevchenko <igor@carcass.ath.cx>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: PQescapeString handling of \0
Date: Mon, 29 Sep 2003 14:22:01 -0400
Message-ID: <27075.1064859721@sss.pgh.pa.us> (raw)
In-Reply-To: <200309291949.26188.igor@carcass.ath.cx>
References: <200309291949.26188.igor@carcass.ath.cx>
Igor Shevchenko <igor@carcass.ath.cx> writes:
> Here's a patch which makes PQescapeString stop escaping when \0 is seen.
Hm. Is that really the right behavior? Given that the function is
defined to take a counted string rather than a null-terminated string,
I'd sort of expect it to turn \0 into "\000" or some such. Of course,
given that this could overflow the specified size of the return buffer,
one might simply conclude that the defined API is broken ...
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-interfaces@postgresql.org
Cc: tgl@sss.pgh.pa.us, igor@carcass.ath.cx
Subject: Re: PQescapeString handling of \0
In-Reply-To: <27075.1064859721@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox