all repos — openbox @ 62e068eabd23405bf5378165892a337926b3ec24

openbox fork - make it a bit more like ryudo

when a bool field is empty return false, not signal 11.. :|
Dana Jansens danakj@orodu.net
commit

62e068eabd23405bf5378165892a337926b3ec24

parent

b645e3720d497fa0111c1b34f0484d1b17358d14

1 files changed, 3 insertions(+), 3 deletions(-)

jump to
M parser/parse.cparser/parse.c

@@ -251,11 +251,11 @@ gboolean parse_bool(xmlDocPtr doc, xmlNodePtr node)

{ xmlChar *c = xmlNodeListGetString(doc, node->children, TRUE); gboolean b = FALSE; - if (!xmlStrcasecmp(c, (const xmlChar*) "true")) + if (c && !xmlStrcasecmp(c, (const xmlChar*) "true")) b = TRUE; - else if (!xmlStrcasecmp(c, (const xmlChar*) "yes")) + else if (c && !xmlStrcasecmp(c, (const xmlChar*) "yes")) b = TRUE; - else if (!xmlStrcasecmp(c, (const xmlChar*) "on")) + else if (c && !xmlStrcasecmp(c, (const xmlChar*) "on")) b = TRUE; xmlFree(c); return b;