call al_unref_user_event in event loop on user events

This commit is contained in:
Sebastian Krzyszkowiak 2017-11-26 10:39:13 +01:00
parent 1f96d6f364
commit 1b657bd70e

View file

@ -523,6 +523,9 @@ SYMBOL_INTERNAL void libsuperderpy_mainloop(void* g) {
#endif
}
EventGamestates(game, &ev);
if (ALLEGRO_EVENT_TYPE_IS_USER(ev.type)) {
al_unref_user_event(&ev.user);
}
}
}