diff options
Diffstat (limited to 'Python/ast.c')
-rw-r--r-- | Python/ast.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Python/ast.c b/Python/ast.c index ca832aa..b356192 100644 --- a/Python/ast.c +++ b/Python/ast.c @@ -2197,6 +2197,8 @@ alias_for_import_name(struct compiling *c, const node *n) } else { alias_ty a = alias_for_import_name(c, CHILD(n, 0)); + if (!a) + return NULL; if (strcmp(STR(CHILD(n, 1)), "as") != 0) { ast_error(n, "must use 'as' in import"); return NULL; |