For https://bugzilla.gnome.org/show_bug.cgi?id=747437 just use the mutex to protect access to those variables