OSDN Git Service

Cause pg_proc.probin to be declared as text, not bytea. Everything was
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 4 Aug 2009 04:04:12 +0000 (04:04 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 4 Aug 2009 04:04:12 +0000 (04:04 +0000)
commitf192e4a5d0a041a5353d43fa10b6fe675a1c01fa
treed52db039522fbecaf248b0c82e56538eec83a440
parentbe6bca23b34b6e59f1deed1d6b44bb434dbe890e
Cause pg_proc.probin to be declared as text, not bytea.  Everything was
already treating it as text anyway, to the point that I couldn't find anything
to change except the datatype markings in catalog/*.h.  The only effect that
the bytea declaration had was to cause byteaout() to be invoked when pg_dump
(or another client program) inspected the column value.  Since pg_dump wasn't
expecting that, but just treating what it got as text, the net result is that
dump and reload would mangle any backslashes or non-ASCII characters in the
filename string for a C-language function.  That is a very long-standing bug,
but given the lack of field complaints it doesn't seem worth trying to find
a back-patchable fix.  We'll just make this change to fix it going forward.

This change will also forestall problems after the planned change to let bytea
emit hex output instead of escaped characters.
doc/src/sgml/catalogs.sgml
src/include/catalog/catversion.h
src/include/catalog/pg_attribute.h
src/include/catalog/pg_proc.h