[Python-checkins] cpython: Issue #19437: Fix r_object() of marshal module, handle r_byte() failure for

victor.stinner python-checkins at python.org
Thu Oct 31 17:24:02 CET 2013


http://hg.python.org/cpython/rev/9e836a945ea9
changeset:   86808:9e836a945ea9
user:        Victor Stinner <victor.stinner at gmail.com>
date:        Thu Oct 31 17:07:08 2013 +0100
summary:
  Issue #19437: Fix r_object() of marshal module, handle r_byte() failure for
TYPE_SMALL_TUPLE

files:
  Python/marshal.c |  2 ++
  1 files changed, 2 insertions(+), 0 deletions(-)


diff --git a/Python/marshal.c b/Python/marshal.c
--- a/Python/marshal.c
+++ b/Python/marshal.c
@@ -1101,6 +1101,8 @@
 
     case TYPE_SMALL_TUPLE:
         n = (unsigned char) r_byte(p);
+        if (PyErr_Occurred())
+            break;
         goto _read_tuple;
     case TYPE_TUPLE:
         n = r_long(p);

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list