diff options
author | Christian Heimes <christian@cheimes.de> | 2007-11-15 02:26:46 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2007-11-15 02:26:46 (GMT) |
commit | 2be03734f89fa0a5de0a2426790be2d16440fb68 (patch) | |
tree | 7d41e63de62d8ebbc41a7d3b46604fe84f65aff6 /Modules/_ctypes | |
parent | 70021d716456ffcca9caba707a735e845e18dd6e (diff) | |
download | cpython-2be03734f89fa0a5de0a2426790be2d16440fb68.zip cpython-2be03734f89fa0a5de0a2426790be2d16440fb68.tar.gz cpython-2be03734f89fa0a5de0a2426790be2d16440fb68.tar.bz2 |
Added some additional checks for sys.std?? is None, see #1440
Diffstat (limited to 'Modules/_ctypes')
-rw-r--r-- | Modules/_ctypes/callbacks.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_ctypes/callbacks.c b/Modules/_ctypes/callbacks.c index 9f5e5d0..9e1aa4f 100644 --- a/Modules/_ctypes/callbacks.c +++ b/Modules/_ctypes/callbacks.c @@ -17,7 +17,7 @@ PrintError(char *msg, ...) va_start(marker, msg); vsnprintf(buf, sizeof(buf), msg, marker); va_end(marker); - if (f) + if (f != NULL && f != Py_None) PyFile_WriteString(buf, f); PyErr_Print(); } |