Remove dead code from tracemalloc (GH-21029)

tracemalloc_get_frame() checked filename == NULL two times in a row.

Signed-off-by: Christian Heimes <christian@python.org>
This commit is contained in:
Christian Heimes 2020-06-27 14:13:47 +02:00 committed by GitHub
parent 20a7902175
commit 9cfcdb7d6e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 4 deletions

View File

@ -319,10 +319,6 @@ tracemalloc_get_frame(PyFrameObject *pyframe, frame_t *frame)
return;
}
assert(filename != NULL);
if (filename == NULL)
return;
if (!PyUnicode_Check(filename)) {
#ifdef TRACE_DEBUG
tracemalloc_error("filename is not a unicode string");