Skip to content

Commit d60bdf2

Browse files
miss-islingtonAlexey Izbyshev
andauthored
closes bpo-34504: Remove the useless NULL check in PySequence_Check(). (GH-8935)
Reported by Svace static analyzer. (cherry picked from commit b57b4ac) Co-authored-by: Alexey Izbyshev <[email protected]>
1 parent 323a91b commit d60bdf2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Objects/abstract.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1477,7 +1477,7 @@ PySequence_Check(PyObject *s)
14771477
{
14781478
if (PyDict_Check(s))
14791479
return 0;
1480-
return s != NULL && s->ob_type->tp_as_sequence &&
1480+
return s->ob_type->tp_as_sequence &&
14811481
s->ob_type->tp_as_sequence->sq_item != NULL;
14821482
}
14831483

0 commit comments

Comments
 (0)