summaryrefslogtreecommitdiffstats
path: root/Modules/_json.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/_json.c')
-rw-r--r--Modules/_json.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/_json.c b/Modules/_json.c
index 4fcaa07..c7cfe50 100644
--- a/Modules/_json.c
+++ b/Modules/_json.c
@@ -1277,13 +1277,13 @@ _encoded_const(PyObject *obj)
{
/* Return the JSON string representation of None, True, False */
if (obj == Py_None) {
- return Py_NewRef(&_Py_ID(null));
+ return &_Py_ID(null);
}
else if (obj == Py_True) {
- return Py_NewRef(&_Py_ID(true));
+ return &_Py_ID(true);
}
else if (obj == Py_False) {
- return Py_NewRef(&_Py_ID(false));
+ return &_Py_ID(false);
}
else {
PyErr_SetString(PyExc_ValueError, "not a const");