Kaydet (Commit) c8278a72 authored tarafından Michael Meeks's avatar Michael Meeks

gtk: tolerate NULL from gdk_screen_get_monitor_plug_name

üst b67ae8dd
......@@ -118,7 +118,7 @@ static int _fallback_get_primary_monitor (GdkScreen *pScreen)
for (int i = 0; i < max && ret < 0; i++)
{
char *name = gdk_screen_get_monitor_plug_name (pScreen, i);
if (!g_ascii_strncasecmp (name, "LVDS", 4))
if (name && !g_ascii_strncasecmp (name, "LVDS", 4))
ret = i;
g_free (name);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment