Re: [HACKERS] outfuncs.c utility statement support

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: [HACKERS] outfuncs.c utility statement support
Дата
Msg-id 2071d3c8-3520-4f02-d1a6-bceb933f8779@2ndquadrant.com
обсуждение исходный текст
Ответ на [HACKERS] outfuncs.c utility statement support  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Ответы Re: [HACKERS] outfuncs.c utility statement support  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
Re: [HACKERS] outfuncs.c utility statement support  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 6/13/17 11:25, Peter Eisentraut wrote:
> Running with --debug-print-parse=on, executing
> 
> create table test1 (a int, b text);
> 
> gives output that is truncated somewhere in the middle (possibly a null
> byte)

So this seems to be a pretty basic bug.  Some node fields of type char
may be zero, and so printing them as a zero byte just truncates the
whole output string.  This could be fixed by printing chars like strings
with the full escaping mechanism.  See attached patch.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Вложения

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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: [HACKERS] Detection of IPC::Run presence in SSL TAP tests
Следующее
От: Amit Langote
Дата:
Сообщение: Re: [HACKERS] A bug in mapping attributes in ATExecAttachPartition()