From: SourceForge.net <no...@so...> - 2003-11-08 05:20:07
|
Bugs item #838317, was opened at 2003-11-08 05:20 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=116528&aid=838317&group_id=16528 Category: libpq Group: None Status: Open Resolution: None Priority: 5 Submitted By: James Matthew Farrow (jmfarrow) Assigned to: Nobody/Anonymous (nobody) Summary: Memory corruption in bytea handling Initial Comment: In unQuoteBytea the line (near the end) sout[j] = (char)0; in both unecessary (since Py_BuildValue for s# takes a length) and wrong. The memory allocated for sout is only the same size as sin. If no characters require unquoting in sin then this NUL ends up being placed _outside_ the allocated memory and will corrupt things. The line should be removed. I suspect an extraneous NUL is also being appended in libPQquoteBytea. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=116528&aid=838317&group_id=16528 |