Fix potential NULL pointer dereference in update_symbols()
symtable_analyze() calls analyze_block() with bound=NULL. Theoretically
that NULL can be passed down to update_symbols(). update_symbols() may
deference NULL and pass it to PySet_Contains()
diff --git a/Python/symtable.c b/Python/symtable.c
index 3f03184..45a8c2c 100644
--- a/Python/symtable.c
+++ b/Python/symtable.c
@@ -652,7 +652,7 @@
continue;
}
/* Handle global symbol */
- if (!PySet_Contains(bound, name)) {
+ if (bound && !PySet_Contains(bound, name)) {
Py_DECREF(name);
continue; /* it's a global */
}