]> git.sur5r.net Git - i3/i3status/commitdiff
Bugfix: output auto detect: properly detect ambiguous situations (Thanks mist)
authorMichael Stapelberg <michael@stapelberg.de>
Mon, 4 Feb 2013 20:36:55 +0000 (21:36 +0100)
committerMichael Stapelberg <michael@stapelberg.de>
Mon, 4 Feb 2013 20:36:55 +0000 (21:36 +0100)
fixes #940

src/auto_detect_format.c

index 46e5f95937052a22d449e781efc760c99f60289a..6ec5f731d906eb1269c2bdc2b26fd23a39439914 100644 (file)
@@ -139,7 +139,7 @@ char *auto_detect_format(void) {
         else if (strcasecmp(name, "xmobar") == 0)
             newfmt = "xmobar";
 
-        if (newfmt && format) {
+        if (newfmt && format && strcmp(newfmt, format) != 0) {
             fprintf(stderr, "i3status: cannot auto-configure, situation ambiguous (format \"%s\" *and* \"%s\" detected)\n", newfmt, format);
             format = NULL;
             break;