summaryrefslogtreecommitdiff
path: root/src/auto_detect_format.c
diff options
context:
space:
mode:
authorMichael Stapelberg <michael@stapelberg.de>2013-02-04 21:36:55 +0100
committerMichael Stapelberg <michael@stapelberg.de>2013-02-04 21:36:55 +0100
commit68e447d3f6bb7767e4d95458b13ead49d76e5410 (patch)
tree3f81bcf3e4d6e6c7a5c5b534382bb3805c5a8e29 /src/auto_detect_format.c
parenta5a43af1865abc2068b0b502ca7d6ff3ee7108a0 (diff)
Bugfix: output auto detect: properly detect ambiguous situations (Thanks mist)
fixes #940
Diffstat (limited to 'src/auto_detect_format.c')
-rw-r--r--src/auto_detect_format.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/auto_detect_format.c b/src/auto_detect_format.c
index 46e5f95..6ec5f73 100644
--- a/src/auto_detect_format.c
+++ b/src/auto_detect_format.c
@@ -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;