]> granicus.if.org Git - python/commitdiff
Clarify C-style exception handling with proper label name.
authorThomas Wouters <thomas@python.org>
Mon, 27 Feb 2006 22:49:54 +0000 (22:49 +0000)
committerThomas Wouters <thomas@python.org>
Mon, 27 Feb 2006 22:49:54 +0000 (22:49 +0000)
Python/compile.c

index d5555d57d9cd7e7b3b38b6417daaac40dc168e7a..9705ce4e398a2656223a881070ed9169a3cf0b1c 100644 (file)
@@ -266,7 +266,7 @@ PyAST_Compile(mod_ty mod, const char *filename, PyCompilerFlags *flags,
         c.c_arena = arena;
        c.c_future = PyFuture_FromAST(mod, filename);
        if (c.c_future == NULL)
-               goto error;
+               goto finally;
        if (!flags) {
             local_flags.cf_flags = 0;
             flags = &local_flags;
@@ -281,7 +281,7 @@ PyAST_Compile(mod_ty mod, const char *filename, PyCompilerFlags *flags,
        if (c.c_st == NULL) {
                if (!PyErr_Occurred())
                        PyErr_SetString(PyExc_SystemError, "no symtable");
-               goto error;
+               goto finally;
        }
 
        /* XXX initialize to NULL for now, need to handle */
@@ -289,7 +289,7 @@ PyAST_Compile(mod_ty mod, const char *filename, PyCompilerFlags *flags,
 
        co = compiler_mod(&c, mod);
 
error:
finally:
        compiler_free(&c);
        assert(co || PyErr_Occurred());
        return co;