Skip to content

Commit

Permalink
Fix fallback event init condition.
Browse files Browse the repository at this point in the history
  • Loading branch information
gresm committed May 21, 2024
1 parent f4b65ef commit b0654aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src_c/event.c
Original file line number Diff line number Diff line change
Expand Up @@ -1891,7 +1891,7 @@ pg_event_init(pgEventObject *self, PyObject *args, PyObject *kwargs)
int type;
PyObject *dict = NULL;
PyObject *self_t = (PyObject *)Py_TYPE(self);
if (PyObject_HasAttrString(self_t, "type")) {
if (self_t != (PyObject *)&pgEvent_Type) {
PyObject *type_o = PyObject_GetAttrString(self_t, "type");
if (!type_o)
return -1;
Expand Down

0 comments on commit b0654aa

Please sign in to comment.