aboutsummaryrefslogtreecommitdiff
path: root/monsterwm.c
diff options
context:
space:
mode:
authorIvan Kanakarakis <ivan.kanak@gmail.com>2012-06-30 22:27:58 +0300
committerIvan Kanakarakis <ivan.kanak@gmail.com>2012-07-20 18:52:16 +0300
commitd6d3de3788a4e5bab4e751fedcd241f29cbf4bb8 (patch)
tree3bf72c3f3ac920f30958764a015855c226cb2910 /monsterwm.c
parentfdaab55052eb25591e8736bb7f1fccff97d0d4e7 (diff)
rework prevclient function - negate return conditional
Diffstat (limited to 'monsterwm.c')
-rw-r--r--monsterwm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/monsterwm.c b/monsterwm.c
index 6ac0dab..0c55e0d 100644
--- a/monsterwm.c
+++ b/monsterwm.c
@@ -666,8 +666,8 @@ void next_win(void) {
/* get the previous client from the given
* if no such client, return NULL */
Client* prevclient(Client *c) {
- if (!c || !head->next) return NULL;
- Client *p; for (p = head; p->next && p->next != c; p = p->next);
+ Client *p = NULL;
+ if (c && head->next) for (p = head; p->next && p->next != c; p = p->next);
return p;
}