New submission from Zackery Spytz <zsp...@gmail.com>:

In PyCArrayType_new(), type_attr is assigned to stgdict->proto. If the 
PyDict_Update() call fails in that function, type_attr will be decrefed an 
extra time when stgdict is deallocated.

I'll create a PR for this issue.

----------
components: Extension Modules, ctypes
messages: 338779
nosy: ZackerySpytz
priority: normal
severity: normal
status: open
title: A possible double decref in _ctypes.c's PyCArrayType_new()
versions: Python 3.7, Python 3.8

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue36421>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to