mirror of
https://github.com/postgres/postgres.git
synced 2025-09-09 13:09:39 +03:00
Properly detoast access to bytea field pg_trigger.tgargs. Old code
might cause server crash. Backpatch to 8.2.X.
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/commands/trigger.c,v 1.211 2007/01/05 22:19:26 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/commands/trigger.c,v 1.212 2007/01/25 04:17:46 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -906,8 +906,7 @@ RelationBuildTriggers(Relation relation)
|
||||
char *p;
|
||||
int i;
|
||||
|
||||
val = (bytea *)
|
||||
DatumGetPointer(fastgetattr(htup,
|
||||
val = DatumGetByteaP(fastgetattr(htup,
|
||||
Anum_pg_trigger_tgargs,
|
||||
tgrel->rd_att, &isnull));
|
||||
if (isnull)
|
||||
|
Reference in New Issue
Block a user