diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2017-01-13 06:38:15 (GMT) |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2017-01-13 06:38:15 (GMT) |
commit | 8cbc51ab3d9be00ddc296513d6f39b06b2d6b1a1 (patch) | |
tree | 3e8b654f3593a4371a987e9893fe255d0e896a27 /Modules/_json.c | |
parent | a24dca6a90774ed47fcb37bbe4315a7f8121e4a8 (diff) | |
parent | a6758427fd96741c6a8a1506f933bb0107d2b0a7 (diff) | |
download | cpython-8cbc51ab3d9be00ddc296513d6f39b06b2d6b1a1.zip cpython-8cbc51ab3d9be00ddc296513d6f39b06b2d6b1a1.tar.gz cpython-8cbc51ab3d9be00ddc296513d6f39b06b2d6b1a1.tar.bz2 |
Py_SIZE() was misused for dict.
Diffstat (limited to 'Modules/_json.c')
-rw-r--r-- | Modules/_json.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_json.c b/Modules/_json.c index d3fb784..941f363 100644 --- a/Modules/_json.c +++ b/Modules/_json.c @@ -1609,7 +1609,7 @@ encoder_listencode_dict(PyEncoderObject *s, _PyAccu *acc, if (open_dict == NULL || close_dict == NULL || empty_dict == NULL) return -1; } - if (Py_SIZE(dct) == 0) + if (PyDict_GET_SIZE(dct) == 0) /* Fast path */ return _PyAccu_Accumulate(acc, empty_dict); if (s->markers != Py_None) { |