From: Dana Jansens Date: Wed, 23 Jul 2003 15:06:49 +0000 (+0000) Subject: i already fixed this once :) var declarations go first X-Git-Url: https://git.brokenzipper.com/gitweb?a=commitdiff_plain;h=03186a7bab2c903fdf60c98134551c727808bd0b;p=chaz%2Fopenbox i already fixed this once :) var declarations go first --- diff --git a/plugins/menu/timed_menu.c b/plugins/menu/timed_menu.c index db642fc1..3bf820a7 100644 --- a/plugins/menu/timed_menu.c +++ b/plugins/menu/timed_menu.c @@ -96,15 +96,18 @@ void timed_menu_read_pipe(int fd, void *d) TIMED_MENU_DATA(menu)->buf + TIMED_MENU_DATA(menu)->buflen, num_realloc); if (num_read == 0) { - menu->invalid = TRUE; + xmlDocPtr doc; + xmlNodePtr node; + + menu->invalid = TRUE; menu_clear(menu); TIMED_MENU_DATA(menu)->buf[TIMED_MENU_DATA(menu)->buflen] = '\0'; - xmlDocPtr doc = xmlParseMemory(TIMED_MENU_DATA(menu)->buf, + doc = xmlParseMemory(TIMED_MENU_DATA(menu)->buf, TIMED_MENU_DATA(menu)->buflen); - xmlNodePtr node = xmlDocGetRootElement(doc); + node = xmlDocGetRootElement(doc); if (!xmlStrcasecmp(node->name, (const xmlChar*) "timed_menu")) { if ((node = parse_find_node("item", node->xmlChildrenNode)))