summaryrefslogtreecommitdiffstats
path: root/Python/bytecodes.c
diff options
context:
space:
mode:
Diffstat (limited to 'Python/bytecodes.c')
-rw-r--r--Python/bytecodes.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/bytecodes.c b/Python/bytecodes.c
index 82d7a71..29e1dab 100644
--- a/Python/bytecodes.c
+++ b/Python/bytecodes.c
@@ -1100,7 +1100,7 @@ dummy_func(
inst(POP_EXCEPT, (exc_value -- )) {
_PyErr_StackItem *exc_info = tstate->exc_info;
- Py_XSETREF(exc_info->exc_value, exc_value);
+ Py_XSETREF(exc_info->exc_value, exc_value == Py_None ? NULL : exc_value);
}
inst(RERAISE, (values[oparg], exc -- values[oparg])) {