summaryrefslogtreecommitdiff
path: root/Python/pylifecycle.c
diff options
context:
space:
mode:
authorChristian Heimes <christian@python.org>2015-04-16 17:25:45 +0200
committerChristian Heimes <christian@python.org>2015-04-16 17:25:45 +0200
commit17338b7c0ae59c10a3f47e91f6ea7f3a34681e0c (patch)
treef7b1226cbe43c39aa2bc2384f059041b914ba8b2 /Python/pylifecycle.c
parent73bb19ea7143c943ea88e281feb3a1f7a5c5019d (diff)
downloadcpython-17338b7c0ae59c10a3f47e91f6ea7f3a34681e0c.tar.gz
Remove redundant check for tb != NULL to shut up Coverity . It has been set to Py_None a couple of lines earlier.
CID 1291697 (#1 of 1): Dereference before null check (REVERSE_INULL) check_after_deref: Null-checking tb suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
Diffstat (limited to 'Python/pylifecycle.c')
-rw-r--r--Python/pylifecycle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c
index 56186778f4..a17adf7626 100644
--- a/Python/pylifecycle.c
+++ b/Python/pylifecycle.c
@@ -1283,7 +1283,7 @@ _Py_PrintFatalError(int fd)
goto display_stack;
}
- has_tb = (tb != NULL && tb != Py_None);
+ has_tb = (tb != Py_None);
PyErr_Display(exception, v, tb);
Py_XDECREF(exception);
Py_XDECREF(v);