@@ -236,21 +236,20 @@ static void parse_config_file(const char *map, size_t len)
continue;
p += 7;
for (q = p; q < map + len; q++) {
- if (!(isalnum(*q) || *q == '_'))
- goto found;
+ if (!(isalnum(*q) || *q == '_')) {
+ if (!memcmp(q - 7, "_MODULE", 7))
+ q -= 7;
+ if (q - p > 0)
+ use_config(p, q - p);
+ break;
+ }
}
continue;
- found:
- if (!memcmp(q - 7, "_MODULE", 7))
- q -= 7;
- if (q - p < 0)
- continue;
- use_config(p, q - p);
}
}
-/* test is s ends in sub */
+/* test if s ends in sub */
static int strrcmp(const char *s, const char *sub)
{
int slen = strlen(s);