" ....src_buf hasn't been assigned to yet. ..."
May be copy/paste issue. It has been assigned. Here is the complete stack for bytea size 7480 and 211758.The later
fail.
Pass (bytea size = 7480):
Breakpoint 1, ST_Geometry_Recv (fcinfo=0xbfffcb90) at binary.c:138
138 StringInfo src_buf = (StringInfo) PG_DETOAST_DATUM(PG_GETARG_DATUM(0));
(gdb) p *src_buf
$2 = {data = 0xff0c8d8b <Address 0xff0c8d8b out of bounds>, len = -1031143425, maxlen = -13595335, cursor = 158662655}
(gdb) n
139 SE_ST_GEOMETRY *result = NULL;
(gdb) p *src_buf
$3 = {data = 0x84ce6b2 "º\022\b\003", len = 7480, maxlen = 7481, cursor = 0}
(gdb) bt
#0 ST_Geometry_Recv (fcinfo=0xbfffcb90) at binary.c:139
#1 0x08209ebd in ReceiveFunctionCall ()
#2 0x08209fde in OidReceiveFunctionCall ()
#3 0x0819a5a0 in exec_bind_message ()
#4 0x0819c6e6 in PostgresMain ()
#5 0x0817a4d9 in BackendRun ()
#6 0x08179e03 in BackendStartup ()
#7 0x0817825f in ServerLoop ()
#8 0x0817785b in PostmasterMain ()
#9 0x0813fd1c in main ()
(gdb) c
Continuing.
Fail (bytea size = 211758):
Breakpoint 1, ST_Geometry_Recv (fcinfo=0xbfffcb90) at binary.c:138
138 StringInfo src_buf = (StringInfo) PG_DETOAST_DATUM(PG_GETARG_DATUM(0));
(gdb) p *src_buf
$4 = {data = 0xff0c8d8b <Address 0xff0c8d8b out of bounds>, len = -1031143425, maxlen = -13595335, cursor = 158662655}
(gdb) n
0x0819c4f8 in PostgresMain ()
(gdb) p *src_buf
No symbol "src_buf" in current context.
(gdb) bt
#0 0x0819c4f8 in PostgresMain ()
#1 0x0817a4d9 in BackendRun ()
#2 0x08179e03 in BackendStartup ()
#3 0x0817825f in ServerLoop ()
#4 0x0817785b in PostmasterMain ()
#5 0x0813fd1c in main ()
(gdb)
The pointer moves to PostgresMain (), as soon as I move to next.
Ale.
-----Original Message-----
From: Tom Lane [mailto:tgl@sss.pgh.pa.us]
Sent: Friday, March 23, 2007 2:20 PM
To: Ale Raza
Cc: postgresql-general
Subject: Re: [GENERAL] Insert fail: could not open relation with OID 3221204992
"Ale Raza" <araza@esri.com> writes:
> Breakpoint 3, #####_Recv (fcinfo=0xbfffa3a0) at binary.c:138
> 138 StringInfo src_buf = (StringInfo)
> PG_DETOAST_DATUM(PG_GETARG_DATUM(0));
> (gdb) p *src_buf
> Cannot access memory at address 0x0
At the point where you've stopped, src_buf hasn't been assigned to yet.
regards, tom lane