[hackers] [wmii] Don't give up on tagrules until there's a non-nil and not "nil" tag string.

From: Kris Maglione <jg_AT_suckless.org>
Date: Fri Jun 08 19:57:30 2007

changeset: 2156:df6321d07044
tag: tip
user: Kris Maglione <jg_AT_suckless.org>
date: Fri Jun 08 13:53:16 2007 -0400
summary: Don't give up on tagrules until there's a non-nil and not "nil" tag string.

diff -r 494157cc1655 -r df6321d07044 cmd/wmii/client.c
--- a/cmd/wmii/client.c Fri Jun 08 12:35:19 2007 -0400
+++ b/cmd/wmii/client.c Fri Jun 08 13:53:16 2007 -0400
@@ -930,7 +930,7 @@ apply_rules(Client *c) {
                 for(r=def.tagrules.rule; r; r=r->next)
                         if(!regexec(&r->regex, c->props, 1, &rm, 0)) {
                                 apply_tags(c, r->value);
- if(strcmp(c->tags, "nil"))
+ if(c->tags[0] && strcmp(c->tags, "nil"))
                                         break;
                         }
         if(c->tags[0] == '\0')
Received on Fri Jun 08 2007 - 19:57:30 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:57:17 UTC