[Python-checkins] cpython: Fixed out-of-bounce write to rawmode buffer. The fixed size buffer wasn't
christian.heimes
python-checkins at python.org
Mon Sep 10 03:50:57 CEST 2012
http://hg.python.org/cpython/rev/85cb90f79cbf
changeset: 78946:85cb90f79cbf
user: Christian Heimes <christian at cheimes.de>
date: Mon Sep 10 03:50:48 2012 +0200
summary:
Fixed out-of-bounce write to rawmode buffer. The fixed size buffer wasn't enlarged for the new 'x' flag. The buffer may contain the 5 flags xrwa+ and the \0 byte
files:
Modules/_io/_iomodule.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Modules/_io/_iomodule.c b/Modules/_io/_iomodule.c
--- a/Modules/_io/_iomodule.c
+++ b/Modules/_io/_iomodule.c
@@ -229,7 +229,7 @@
int creating = 0, reading = 0, writing = 0, appending = 0, updating = 0;
int text = 0, binary = 0, universal = 0;
- char rawmode[5], *m;
+ char rawmode[6], *m;
int line_buffering, isatty;
PyObject *raw, *modeobj = NULL, *buffer = NULL, *wrapper = NULL;
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list