Re: PQescapeString handling of \0

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: PQescapeString handling of \0
Дата
Msg-id 27075.1064859721@sss.pgh.pa.us
обсуждение исходный текст
Ответ на PQescapeString handling of \0  (Igor Shevchenko <igor@carcass.ath.cx>)
Ответы Re: PQescapeString handling of \0  (Igor Shevchenko <igor@carcass.ath.cx>)
Список pgsql-interfaces
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


В списке pgsql-interfaces по дате отправления:

Предыдущее
От: Igor Shevchenko
Дата:
Сообщение: PQescapeString handling of \0
Следующее
От: Igor Shevchenko
Дата:
Сообщение: Re: PQescapeString handling of \0