BUG/MEDIUM: spoa/python: Fixing references to None
authorGilchrist Dadaglo <dadaglo@amazon.com>
Tue, 8 Dec 2020 14:37:14 +0000 (14:37 +0000)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 9 Dec 2020 07:39:31 +0000 (08:39 +0100)
commitbdd034947c4a3a6f8c41af9bf6e62b7a74b4ebbc
tree49147522b58b779a598f0bb2ca888dedf8561ec0
parent042f697a0fce0255b569786d29e929a4a41cbc46
BUG/MEDIUM: spoa/python: Fixing references to None

As per https://docs.python.org/3/c-api/none.html, None has to be treated
exactly like other objects for reference counting.
So, when we use it, we need to INCREF and when we are done, DECREF

This patch must be backported as far as 2.0.
contrib/spoa_server/ps_python.c