]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
sysmodule.c: calling sys.settrace() or sys.setprofile() without
authorGuido van Rossum <guido@python.org>
Fri, 19 Jun 1992 13:57:27 +0000 (13:57 +0000)
committerGuido van Rossum <guido@python.org>
Fri, 19 Jun 1992 13:57:27 +0000 (13:57 +0000)
arguments crashed in INCREF() calls which should be XINCREF() calls.

timemodule.c: fix for SEQUENT port (sys/select, struct timezone) by
Jaap Vermeulen

xxobject.c: include modsupport.h

Objects/xxobject.c
Python/sysmodule.c

index 8edf689e18637fbef2b37cd31c6772ba7c5181de..bfe9c842889c6df71a4ab07aa50e8b494ff71470 100644 (file)
@@ -35,6 +35,7 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 /* Xx objects */
 
 #include "allobjects.h"
+#include "modsupport.h"                /* For getargs() etc. */
 
 typedef struct {
        OB_HEAD
index a12595caa8f54c6088c247667b478b8b5b91b299..3a6516ffa442df7b13d10d500f1031cc82a58cde 100644 (file)
@@ -102,7 +102,7 @@ sys_settrace(self, args)
        if (args == None)
                args = NULL;
        else
-               INCREF(args);
+               XINCREF(args);
        XDECREF(sys_trace);
        sys_trace = args;
        INCREF(None);
@@ -117,7 +117,7 @@ sys_setprofile(self, args)
        if (args == None)
                args = NULL;
        else
-               INCREF(args);
+               XINCREF(args);
        XDECREF(sys_profile);
        sys_profile = args;
        INCREF(None);