[Python-checkins] python/dist/src/Parser myreadline.c, 2.33,

mwh at users.sourceforge.net mwh at users.sourceforge.net
Thu Apr 7 12:20:19 CEST 2005

Update of /cvsroot/python/python/dist/src/Parser
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14793/Parser

Modified Files:
      Tag: release24-maint
Log Message:
Backport my recent raw_input() vs no threads build vs SIGINT argh:

In a threads-disabled build, typing Ctrl-C into a raw_input() crashed,
because (essentially) I didn't realise that PY_BEGIN/END_ALLOW_THREADS
actually expanded to nothing under a no-threads build, so if you somehow
NULLed out the threadstate (e.g. by calling PyThread_SaveThread) it would
stay NULLed when you return to Python.  Argh!

Index: myreadline.c
RCS file: /cvsroot/python/python/dist/src/Parser/myreadline.c,v
retrieving revision 2.33
retrieving revision
diff -u -d -r2.33 -r2.33.4.1
--- myreadline.c	8 Jul 2004 15:28:26 -0000	2.33
+++ myreadline.c	7 Apr 2005 10:19:46 -0000
@@ -82,9 +82,13 @@
 #ifdef EINTR
 		if (errno == EINTR) {
 			int s;
 			s = PyErr_CheckSignals();
 			if (s < 0) {
 				return 1;

More information about the Python-checkins mailing list