Kaydet (Commit) 7aeb6ef9 authored tarafından Thomas Wouters's avatar Thomas Wouters

Use HAVE_SNPRINTF, not HAVE_SPRINTF, for checking the availability of

snprintf.
üst 3db5b8cc
...@@ -2420,7 +2420,7 @@ PySocket_getnameinfo(PyObject *self, PyObject *args) ...@@ -2420,7 +2420,7 @@ PySocket_getnameinfo(PyObject *self, PyObject *args)
n = PyArg_ParseTuple(sa, "si|ii", &hostp, &port, &flowinfo, scope_id); n = PyArg_ParseTuple(sa, "si|ii", &hostp, &port, &flowinfo, scope_id);
if (n == 0) if (n == 0)
goto fail; goto fail;
#ifdef HAVE_SPRINTF #ifdef HAVE_SNPRINTF
snprintf(pbuf, sizeof(pbuf), "%d", port); snprintf(pbuf, sizeof(pbuf), "%d", port);
#else #else
sprintf(pbuf, "%d", port); sprintf(pbuf, "%d", port);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment