Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug
Bug#: 192858
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Python Gentoo Team <python@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Sean McLean <smclean@gmail.com>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 192858 depends on: Show dependency tree
Bug 192858 blocks: 148333
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2007-09-17 21:32 0000
The pyvorbis-1.4-r2 ebuild includes a patch (pyvorbis-1.4-python25.patch) to
make pyvorbis 1.4 work with Python 2.5, but it does not apply it.  

Furthermore, the patch is not synced up with the newest pyvorbis vanilla
tarball, and otherwise needs changing to be compatible with epatch

On my system, I've modified the patch, and I've modified the ebuild to use
epatch to apply it.  After doing so, pyvorbis successfully builds and works
with python 2.5.

My modified copy of this patch (pyvorbis-1.4-python25.patch) follows:

--- src/pyvorbiscodec.c.orig    2007-07-19 17:57:15.000000000 +0200
+++ src/pyvorbiscodec.c 2007-07-19 20:13:59.000000000 +0200
@@ -118,7 +118,7 @@
 {
   vorbis_dsp_clear(PY_DSP(self));
   Py_XDECREF(((py_dsp *)self)->parent);
-  PyMem_DEL(self);
+  PyObject_DEL(self);
 }

 static PyObject*
@@ -447,7 +447,7 @@
 {
   vorbis_block_clear(PY_BLOCK(self));
   Py_XDECREF(((py_block *)self)->parent);
-  PyMem_DEL(self);
+  PyObject_DEL(self);
 }

 static PyObject*
--- src/pyvorbisfile.c.orig     2007-07-19 17:57:15.000000000 +0200
+++ src/pyvorbisfile.c  2007-07-19 20:25:27.000000000 +0200
@@ -173,8 +173,7 @@
   if (ret == NULL) {
     PyMem_DEL(newobj);
     return NULL;
-  } else
-    Py_DECREF(ret);
+  }

   return (PyObject *) newobj;
 }
@@ -190,9 +189,9 @@
     /* If file was opened from a file object, decref it, so it can
        close */
     Py_DECREF(py_self->py_file);
   }
-
-  PyMem_DEL(self);
+  free(py_self->ovf);
+  PyObject_DEL(self);
 }

 static PyObject *
--- src/pyvorbisinfo.c.orig     2007-07-19 17:57:15.000000000 +0200
+++ src/pyvorbisinfo.c  2007-07-19 20:36:25.000000000 +0200
@@ -134,7 +134,7 @@
 static void
 py_ov_info_dealloc(PyObject *self)
 {
-  PyMem_DEL(self);
+  PyObject_DEL(self);
 }

 #define CMP_RET(x) \
@@ -418,7 +418,7 @@
     free(ovc_self->vc);
   }

-  PyMem_DEL(self);
+  PyObject_DEL(self);
 }



Reproducible: Always

Steps to Reproduce:
1. Attempt to use pyvorbis-1.4-r2 with Python 2.5 (any version)

Actual Results:  
Python crashes when reading tags with pyvorbis.

Expected Results:  
Python does not crash when reading tags with pyvorbis.

I ran across this bug when python 2.5 was pushed out to ~amd64, and I'd imagine
many other users are currently experiencing problems due to it, as pyvorbis is
a dependency in quite a few python audio applications.

------- Comment #1 From Ali Polatel (RETIRED) 2007-09-19 23:38:50 0000 -------
The new version 1.4-r3 in CVS applies the updated python-2.5 patch and works
fine on 64 bit. Thanks for reporting ;)

Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug