Skip to content

Commit

Permalink
Initialize value
Browse files Browse the repository at this point in the history
  • Loading branch information
markshannon committed May 3, 2024
1 parent 94bf898 commit d54afaf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Objects/dictobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -6604,7 +6604,7 @@ _PyDict_NewKeysForClass(PyHeapTypeObject *cls)
if (cls->ht_type.tp_dict) {
PyObject *attrs = PyDict_GetItem(cls->ht_type.tp_dict, &_Py_ID(__static_attributes__));
if (attrs != NULL && PyTuple_Check(attrs)) {
for (Py_ssize_t i; i < PyTuple_GET_SIZE(attrs); i++) {
for (Py_ssize_t i = 0; i < PyTuple_GET_SIZE(attrs); i++) {
PyObject *key = PyTuple_GET_ITEM(attrs, i);
Py_hash_t hash;
if (PyUnicode_CheckExact(key) && (hash = unicode_get_hash(key)) != -1) {
Expand Down

0 comments on commit d54afaf

Please sign in to comment.