Fixes mutex unlock() after destruction
CleanEventRegistry