diff Python/ceval.c @ 61993:e766c0d86cff

use atomic structures in non-thread version
author Benjamin Peterson <benjamin@python.org>
date Sun, 30 May 2010 14:49:32 +0000
parents cab14be0ada1
children c8d5d1205fe8
line wrap: on
line diff
--- a/Python/ceval.c	Sun May 30 13:18:47 2010 +0000
+++ b/Python/ceval.c	Sun May 30 14:49:32 2010 +0000
@@ -598,7 +598,7 @@
 } pendingcalls[NPENDINGCALLS];
 static volatile int pendingfirst = 0;
 static volatile int pendinglast = 0;
-static volatile int pendingcalls_to_do = 0;
+static _Py_atomic_int pendingcalls_to_do = {0};
 
 int
 Py_AddPendingCall(int (*func)(void *), void *arg)