summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@suse.com>2011-10-31 14:15:02 +0000
committerMichael Meeks <michael.meeks@suse.com>2011-10-31 14:16:27 +0000
commitc8278a72b36adfd7f0a44dbedc558961dfd0dd24 (patch)
treeab3aa29921d3a3597862e92dd0d9717bbac7250f /vcl
parentb67ae8dd02a1b9aeb35ef123017d8c02d1d8aaf5 (diff)
gtk: tolerate NULL from gdk_screen_get_monitor_plug_name
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/gtk/app/gtksys.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/unx/gtk/app/gtksys.cxx b/vcl/unx/gtk/app/gtksys.cxx
index b752cce84891..dbe1c47c7e89 100644
--- a/vcl/unx/gtk/app/gtksys.cxx
+++ b/vcl/unx/gtk/app/gtksys.cxx
@@ -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);
}