[Python-checkins] r52111 - python/branches/release24-maint/Modules/_tkinter.c

andrew.kuchling python-checkins at python.org
Tue Oct 3 21:02:58 CEST 2006


Author: andrew.kuchling
Date: Tue Oct  3 21:02:58 2006
New Revision: 52111

Modified:
   python/branches/release24-maint/Modules/_tkinter.c
Log:
[Backport r51229 | neal.norwitz]

Don't deref v if it's NULL.

Klocwork #214



Modified: python/branches/release24-maint/Modules/_tkinter.c
==============================================================================
--- python/branches/release24-maint/Modules/_tkinter.c	(original)
+++ python/branches/release24-maint/Modules/_tkinter.c	Tue Oct  3 21:02:58 2006
@@ -2482,8 +2482,10 @@
 	}
 
 	v = Tktt_New(func);
-	v->token = Tcl_CreateTimerHandler(milliseconds, TimerHandler,
-					  (ClientData)v);
+	if (v) {
+		v->token = Tcl_CreateTimerHandler(milliseconds, TimerHandler,
+						  (ClientData)v);
+	}
 
 	return (PyObject *) v;
 }


More information about the Python-checkins mailing list