]> granicus.if.org Git - python/commitdiff
Issue #19437: Fix r_object() of marshal module, handle r_byte() failure for
authorVictor Stinner <victor.stinner@gmail.com>
Thu, 31 Oct 2013 16:07:08 +0000 (17:07 +0100)
committerVictor Stinner <victor.stinner@gmail.com>
Thu, 31 Oct 2013 16:07:08 +0000 (17:07 +0100)
TYPE_SMALL_TUPLE

Python/marshal.c

index 411f1e078210f7de1122029791fe1390c6000c37..598269fa722745e84e72f89ebbf95e29e6d4edc5 100644 (file)
@@ -1101,6 +1101,8 @@ r_object(RFILE *p)
 
     case TYPE_SMALL_TUPLE:
         n = (unsigned char) r_byte(p);
+        if (PyErr_Occurred())
+            break;
         goto _read_tuple;
     case TYPE_TUPLE:
         n = r_long(p);