summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2012-09-10 01:50:48 (GMT)
committerChristian Heimes <christian@cheimes.de>2012-09-10 01:50:48 (GMT)
commit89ff3c7f20ef2451041f80350f4718e3e4e735a1 (patch)
treebc874ffd4310f75cb1b83885daedba6fe339a0a6 /Modules
parent310f81449a5d95d4d30a17a348929cb91b6e8307 (diff)
downloadcpython-89ff3c7f20ef2451041f80350f4718e3e4e735a1.zip
cpython-89ff3c7f20ef2451041f80350f4718e3e4e735a1.tar.gz
cpython-89ff3c7f20ef2451041f80350f4718e3e4e735a1.tar.bz2
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
Diffstat (limited to 'Modules')
-rw-r--r--Modules/_io/_iomodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_io/_iomodule.c b/Modules/_io/_iomodule.c
index 15781ac..0622c58 100644
--- a/Modules/_io/_iomodule.c
+++ b/Modules/_io/_iomodule.c
@@ -229,7 +229,7 @@ io_open(PyObject *self, PyObject *args, PyObject *kwds)
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;