From 47485c03843e0a1b0bb8d55d260cd5e5ca08dbe9 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Fri, 19 Sep 2025 10:30:11 +0100 Subject: [PATCH] gh-129813, PEP 782: Fix refleak in sock_recvfrom() (GH-139151) --- Modules/socketmodule.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c index 8be06bddf3d0..92e6be68192d 100644 --- a/Modules/socketmodule.c +++ b/Modules/socketmodule.c @@ -4191,6 +4191,7 @@ sock_recvfrom(PyObject *self, PyObject *args) } ret = PyTuple_Pack(2, buf, addr); + Py_DECREF(buf); finally: Py_XDECREF(addr); -- 2.47.3