Hello community, here is the log from the commit of package python-pam checked in at Sat Feb 2 00:08:50 CET 2008. -------- --- python-pam/python-pam.changes 2008-01-30 18:38:06.000000000 +0100 +++ python-pam/python-pam.changes 2008-02-01 20:07:22.000000000 +0100 @@ -1,0 +2,10 @@ +Fri Feb 1 20:06:40 CET 2008 - matejcik@suse.cz + +- removed errorneous free() calls on pam_response structures + +------------------------------------------------------------------- +Wed Jan 30 18:38:27 CET 2008 - matejcik@suse.cz + +- submitting to SLES10 SP2, as per fate#302853 + +------------------------------------------------------------------- New: ---- PyPAM-0.5.0-nofree.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pam.spec ++++++ --- /var/tmp/diff_new_pack.O26792/_old 2008-02-01 23:38:31.000000000 +0100 +++ /var/tmp/diff_new_pack.O26792/_new 2008-02-01 23:38:31.000000000 +0100 @@ -19,7 +19,7 @@ Provides: PyPAM Obsoletes: PyPAM Version: 0.5.0 -Release: 1 +Release: 3 Summary: Python bindings for PAM %define tarname PyPAM Source: %{tarname}-%{version}.tar.bz2 @@ -33,6 +33,8 @@ # removes DECREF on borrowed reference Patch4: %{tarname}-0.5.0-gnu99.patch # switch gcc to gnu99 mode (we need that for strdup()) +Patch5: %{tarname}-0.5.0-nofree.patch + # removes incorrect attempts to free pam_response structures BuildRoot: %{_tmppath}/%{name}-%{version}-build %{py_requires} @@ -56,9 +58,10 @@ %patch2 %patch3 %patch4 +%patch5 %build -#export CFLAGS="$RPM_OPT_FLAGS" +export CFLAGS="-O0" python setup.py build %install @@ -73,6 +76,10 @@ %doc examples %changelog +* Fri Feb 01 2008 matejcik@suse.cz +- removed errorneous free() calls on pam_response structures +* Wed Jan 30 2008 matejcik@suse.cz +- submitting to SLES10 SP2, as per fate#302853 * Wed Jan 30 2008 matejcik@suse.cz - update to 0.5.0: - license changed to LGPL ++++++ PyPAM-0.5.0-nofree.patch ++++++ --- PAMmodule.c +++ PAMmodule.c @@ -24,8 +24,6 @@ char *service; char *user; PyObject *callback; - struct pam_response *response_data; - int response_len; PyObject *user_data; void *dlh1, *dlh2; } PyPAMObject; @@ -54,15 +52,6 @@ Py_INCREF(self); - if (NULL != self->response_data) { - for (int i = 0; i < self->response_len; i++) { - free(self->response_data[0].resp); - } - free(self->response_data); - self->response_data = NULL; - self->response_len = 0; - } - PyObject* msgList = PyList_New(num_msg); for (int i = 0; i < num_msg; i++) { @@ -94,16 +83,12 @@ if (!PyArg_ParseTuple(respTuple, "si", &resp_text, &resp_retcode)) { free(*resp); Py_DECREF(respList); - return PAM_CONV_ERR; + return PAM_CONV_ERR; // FIXME responses filled before the error leak here } spr->resp = strdup(resp_text); spr->resp_retcode = resp_retcode; } - // Save this so we can free it later. - self->response_data = *resp; - self->response_len = PyList_Size(respList); - Py_DECREF(respList); return PAM_SUCCESS; @@ -143,8 +128,6 @@ p->user = NULL; Py_INCREF(Py_None); p->callback = Py_None; - p->response_data = NULL; - p->response_len = 0; Py_INCREF(Py_None); p->user_data = Py_None; ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org