IdleWork() calls on destructed ScintillaGTK objects.
The idle callback removal clause in the ScintillaGTK destructor got broken in [code:4e5c321dda8e69104cb7b639c3107dc11dbc00f6], leading to the callback not being removed thus possibly running after the instance destruction.
g_idle_add() with a custom user data, thus making the
g_source_remove_by_user_data() call in the destructor incorrect, as we give it our own user data, not GDK's wrapper one.
Fix the callback removal not to use user data matching to avoid this.
Attached are 3 possible implementations of a fix:
IdlerIDso the GTK platform can use it as such. No other platform seem to use
WorkNeeded::activeand adds a private member to
ScintillaGTKwith the same purpose. Again, no other platform seem to use
WorkNeeded::active, hence the removal.
Log in to post a comment.