_mssql on Python 2.5 Beta 2
Andrew MacIntyre
andymac at bullseye.apana.org.au
Mon Jul 24 09:13:16 EDT 2006
mattjohnthomson at googlemail.com wrote:
> I'm trying to use the _mssql module from
> http://pymssql.sourceforge.net/. It works fine on Python 2.4. I've
> just installed Python 2.5 Beta 2 on my Linux box and, whenever I try
> and run the mssql.close() function, or close the program, I get the
> following message:
>
> *** glibc detected *** python2.5: free(): invalid pointer: 0xb7f08320
I'm assuming that you recompiled the extension, rather than installed
a binary built with a Python 2.4 installation.
Python 2.5 tightens the requirements that memory allocated via one
memory management API family must be released via calls through the
same API family - eg malloc() -> free(); PyMem_Malloc() -> PyMem_Free();
PyObject_Malloc() -> PyObject_Free(). I think I recall something about
this in one of the "whats new" type docs.
A fair bit of code erroneously assumes that free() can be used to
release any block of memory, regardless of which API family was used to
allocate the memory. This code needs to be fixed.
--
-------------------------------------------------------------------------
Andrew I MacIntyre "These thoughts are mine alone..."
E-mail: andymac at bullseye.apana.org.au (pref) | Snail: PO Box 370
andymac at pcug.org.au (alt) | Belconnen ACT 2616
Web: http://www.andymac.org/ | Australia
More information about the Python-list
mailing list