[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread miss-islington


miss-islington  added the comment:


New changeset ea21206626d0907e0ecfd3efbb186f14f1a8a5d4 by Miss Islington (bot) 
in branch '2.7':
closes bpo-34477: Objects/typeobject.c: Add missing NULL check to type_init() 
(GH-8876)
https://github.com/python/cpython/commit/ea21206626d0907e0ecfd3efbb186f14f1a8a5d4


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread miss-islington


miss-islington  added the comment:


New changeset fbe359a5e0b22e96065d24d033bebf27cdb374be by Miss Islington (bot) 
in branch '3.6':
closes bpo-34477: Objects/typeobject.c: Add missing NULL check to type_init() 
(GH-8876)
https://github.com/python/cpython/commit/fbe359a5e0b22e96065d24d033bebf27cdb374be


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread miss-islington


miss-islington  added the comment:


New changeset 609062a23f018f4ffc180a88435d61f871165518 by Miss Islington (bot) 
in branch '3.7':
closes bpo-34477: Objects/typeobject.c: Add missing NULL check to type_init() 
(GH-8876)
https://github.com/python/cpython/commit/609062a23f018f4ffc180a88435d61f871165518


--
nosy: +miss-islington

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread miss-islington


Change by miss-islington :


--
pull_requests: +8361

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread miss-islington


Change by miss-islington :


--
pull_requests: +8360

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread Benjamin Peterson


Benjamin Peterson  added the comment:


New changeset f6247aac08c1a79d0479145a405718bb76dba434 by Benjamin Peterson 
(Alexey Izbyshev) in branch 'master':
closes bpo-34477: Objects/typeobject.c: Add missing NULL check to type_init() 
(GH-8876)
https://github.com/python/cpython/commit/f6247aac08c1a79d0479145a405718bb76dba434


--
nosy: +benjamin.peterson
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread miss-islington


Change by miss-islington :


--
pull_requests: +8359

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


--
keywords: +patch
pull_requests: +8351
stage:  -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34477] Objects/typeobject.c: Missing NULL check in type_init()

2018-08-23 Thread Alexey Izbyshev


New submission from Alexey Izbyshev :

The return value of PyTuple_GetSlice() at 
https://github.com/python/cpython/blob/48ce4897f8f8d91d948ecd1241ffab002df2be9e/Objects/typeobject.c#L2297
 is not checked for NULL and then dereferenced.

Reported by Svace static analyzer.

Currently, PyTuple_GetSlice() for a zero-length slice can fail only if it's the 
first zero-length tuple ever created. If there is an invariant that at least 
one zero-length tuple exists on any type_init() call, the check may be replaced 
with an assert.

--
components: Interpreter Core
messages: 323951
nosy: berker.peksag, izbyshev, pitrou, serhiy.storchaka
priority: normal
severity: normal
status: open
title: Objects/typeobject.c: Missing NULL check in type_init()
type: behavior
versions: Python 2.7, Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com