summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
Diffstat (limited to 'Modules')
-rw-r--r--Modules/socketmodule.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c
index e852287..a1a90f4 100644
--- a/Modules/socketmodule.c
+++ b/Modules/socketmodule.c
@@ -3109,6 +3109,7 @@ socket_gethostname(PyObject *self, PyObject *unused)
PyUnicode_AS_UNICODE(result),
size+1))
return result;
+ Py_DECREF(result);
}
return PyErr_SetExcFromWindowsErr(PyExc_WindowsError, GetLastError());
}