Unix Technical Forum

BUG #2502: PQclear: "invalid next size"

This is a discussion on BUG #2502: PQclear: "invalid next size" within the pgsql Bugs forums, part of the PostgreSQL category; --> The following bug has been logged online: Bug reference: 2502 Logged by: J. R. Fisher Email address: psql@jeffryfisher.net PostgreSQL ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Bugs

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-10-2008, 10:05 AM
J. R. Fisher
 
Posts: n/a
Default BUG #2502: PQclear: "invalid next size"


The following bug has been logged online:

Bug reference: 2502
Logged by: J. R. Fisher
Email address: psql@jeffryfisher.net
PostgreSQL version: 8.1
Operating system: Linux
Description: PQclear: "invalid next size"
Details:

One patch of C++, two programs using it. One program runs without a hitch,
the other always explodes. In the debugger, this is what's executing:

result = PQexec (conn->handle, cmd);// char* cmd= "BEGIN"
if (PQresultStatus (result) != PGRES_COMMAND_OK) {
... // skipped because result *is* OK
}
if (!savingCursor) {
PQclear (result); // blows up here, but only in one program, not the
others

*** glibc detected *** free(): invalid next size (normal): 0x08068ab0

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-10-2008, 10:05 AM
Tom Lane
 
Posts: n/a
Default Re: BUG #2502: PQclear: "invalid next size"

"J. R. Fisher" <psql@jeffryfisher.net> writes:
> *** glibc detected *** free(): invalid next size (normal): 0x08068ab0


Sounds like a memory clobber. The odds are extremely high that the
clobber is in your own code, not libpq. If nothing else comes to mind,
you could probably use ElectricFence or some other debugging-malloc
package to help find the problem.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 11:49 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com