Bug 640432
Summary: | crash in mod_python when accessing a koji server | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Fabrice Bellet <fabrice> | ||||
Component: | mod_python | Assignee: | Joe Orton <jorton> | ||||
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | high | Docs Contact: | |||||
Priority: | high | ||||||
Version: | 14 | CC: | a.badger, abuse, bojan, dmalcolm, erik-fedora, ivazqueznet, jafo, james.antill, jonathansteffan, jorton, me, net147, robinlee.sysu | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | mod_python-3.3.1-14.fc14 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2010-11-17 23:21:28 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Bug Depends On: | |||||||
Bug Blocks: | 620842 | ||||||
Attachments: |
|
Description
Fabrice Bellet
2010-10-05 19:34:10 UTC
mod_python uses the PyCObject API, but this was deprecated in 2.7 (and, in fact will be removed in 3.2, though AIUI, mod_python won't be ported to python 3) From a prepped source tree of mod_python-3.3.1-13: find -exec grep -nH -e "PyCObject" "{}" \; ./src/serverobject.c:228: return PyCObject_FromVoidPtr(self->server, 0); ./src/requestobject.c:1614: return PyCObject_FromVoidPtr(self->request_rec, 0); ./src/connobject.c.buckets:429: return PyCObject_FromVoidPtr(self->conn, 0); ./src/connobject.c:429: return PyCObject_FromVoidPtr(self->conn, 0); ./src/mod_python.c:185: p = PyCObject_FromVoidPtr((void *) idata, NULL); ./src/mod_python.c:264: idata = (interpreterdata *)PyCObject_AsVoidPtr(p); In particular, the final two "grep" hits are in "save_interpreter", and "get_interpreter"; they appear to assume that the call into PyCObject will succeed. If warnings-as-errors is enabled, this will lead to a crash inside Python, perhaps the one seen above. Upstream notes: http://docs.python.org/dev/whatsnew/2.7.html#capsules Created attachment 454534 [details]
Fix crash by removing use of deprecated functions
This patch replaces use of the PyCObject API with PyCapsule API so that it longer uses deprecated functions or crashes.
The patch works for me. Thanks! This patch also works for me. In my case I had done a fresh beta install, a yum update, and then installed Cobbler. The web interface was causing Seg faults in the Apache error_log. Applying this patch to mod_python and rebuilding allows me to access the site. Previously when I had this problem (a few weeks ago, also on the F14 beta), I had definitely tracked it down to mod_python, but didn't have time to track it further than that. *** Bug 647457 has been marked as a duplicate of this bug. *** I think I'm seeing the same with viewvc on F-14. Anyone has a koji URL to a build where this was fixed? ping -- does this need to be reassigned to mod_python and the patch applied there? Reassigning to mod_python. Please apply the patch and rebuild. Changing priority and severity, because other software is affected by this failure. Any chance we get %{?dist} added to release at the same time, so that it's easier to tell what the package is for? jorton: I'll go ahead and push an update to F14 for with the attached patch. I'll leave it in the testing repository for the full two weeks so holler if you think this is the wrong thing to do and I won't push it to stable. mod_python-3.3.1-14.fc14 has been submitted as an update for Fedora 14. https://admin.fedoraproject.org/updates/mod_python-3.3.1-14.fc14 mod_python-3.3.1-14.fc14 has been pushed to the Fedora 14 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with su -c 'yum --enablerepo=updates-testing update mod_python'. You can provide feedback for this update here: https://admin.fedoraproject.org/updates/mod_python-3.3.1-14.fc14 mod_python-3.3.1-14.fc14 has been pushed to the Fedora 14 stable repository. If problems still persist, please make note of it in this bug report. With mod_python-3.3.1-12.fc14, trac also segfaulted on Fedora 14. The update mod_python-3.3.1-14.fc14 solved the issue. Thanks! |