Commit 827c7832 authored by Xiang Zhang's avatar Xiang Zhang Committed by GitHub

bpo-29873: fix INCREF for possible NULL value in element_getattr() (GH-757)

parent 91f79db0
......@@ -1542,7 +1542,7 @@ element_getattr(ElementObject* self, char* name)
return res;
} else if (strcmp(name, "text") == 0) {
res = element_get_text(self);
Py_INCREF(res);
Py_XINCREF(res);
return res;
}
......
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