summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Python/pystrhex.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Python/pystrhex.c b/Python/pystrhex.c
index a20e30747b..1259ed12df 100644
--- a/Python/pystrhex.c
+++ b/Python/pystrhex.c
@@ -18,6 +18,7 @@ static PyObject *_Py_strhex_impl(const char* argbuf, const Py_ssize_t arglen,
retbuf = (Py_UCS1*) PyMem_Malloc(arglen*2);
if (!retbuf)
return PyErr_NoMemory();
+ retval = NULL; /* silence a compiler warning, assigned later. */
} else {
retval = PyUnicode_New(arglen*2, 127);
if (!retval)