summaryrefslogtreecommitdiffstats
path: root/Python/pythonrun.c
diff options
context:
space:
mode:
authorJeremy Hylton <jeremy@alum.mit.edu>2001-11-28 20:42:20 (GMT)
committerJeremy Hylton <jeremy@alum.mit.edu>2001-11-28 20:42:20 (GMT)
commit518ab1c02a01a1a502fedeccb62ea73f2a952ba7 (patch)
tree4fd0238c7960f0001e8b576656acbbbe0947053e /Python/pythonrun.c
parentef58b319916f6cf2034acc40b411f8405f20416f (diff)
downloadcpython-518ab1c02a01a1a502fedeccb62ea73f2a952ba7.zip
cpython-518ab1c02a01a1a502fedeccb62ea73f2a952ba7.tar.gz
cpython-518ab1c02a01a1a502fedeccb62ea73f2a952ba7.tar.bz2
Use PyOS_snprintf instead of sprintf.
Diffstat (limited to 'Python/pythonrun.c')
-rw-r--r--Python/pythonrun.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/pythonrun.c b/Python/pythonrun.c
index f6217c3..628058b 100644
--- a/Python/pythonrun.c
+++ b/Python/pythonrun.c
@@ -933,7 +933,7 @@ void PyErr_Display(PyObject *exception, PyObject *value, PyObject *tb)
else
PyFile_WriteString(filename, f);
PyFile_WriteString("\", line ", f);
- sprintf(buf, "%d", lineno);
+ PyOS_snprintf(buf, sizeof(buf), "%d", lineno);
PyFile_WriteString(buf, f);
PyFile_WriteString("\n", f);
if (text != NULL)