Fix for GTK crash when scanning hosts.