From: Pinchart, L. <Pin...@PC...> - 2003-06-05 10:09:10
|
Here's a patch that fixes a memory leak in libPQquoteBytea@libpqmodule.c. Bytea are quoted using as much as 5 bytes per input byte (0x00 is quoted '\\000'), so allocating (slen * 4) + 3 is not enough for data that contain lots of 0x00 bytes. The patch has been tested on Windows, with PyPgSQL compiled with VS6. Laurent Pinchart |