- gchar *s = obt_xml_node_string(n);
- if (!g_ascii_strcasecmp(s, "current"))
- o->desktop_current = TRUE;
- if (!g_ascii_strcasecmp(s, "other"))
- o->desktop_other = TRUE;
- else
- o->desktop_number = atoi(s);
+ gchar *s;
+ if ((s = obt_xml_node_string(n))) {
+ if (!g_ascii_strcasecmp(s, "current"))
+ o->desktop_current = TRUE;
+ if (!g_ascii_strcasecmp(s, "other"))
+ o->desktop_other = TRUE;
+ else
+ o->desktop_number = atoi(s);
+ g_free(s);
+ }