about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--config.mk4
-rw-r--r--view.c23
2 files changed, 14 insertions, 13 deletions
diff --git a/config.mk b/config.mk
index 1d73f2b..f65e6fc 100644
--- a/config.mk
+++ b/config.mk
@@ -17,8 +17,8 @@ LIBS = -L/usr/lib -lc -L${X11LIB} -lX11
 # flags
 CFLAGS = -Os ${INCS} -DVERSION=\"${VERSION}\"
 LDFLAGS = ${LIBS}
-#CFLAGS = -g -Wall -O2 ${INCS} -DVERSION=\"${VERSION}\"
-#LDFLAGS = -g ${LIBS}
+CFLAGS = -g -Wall -O2 ${INCS} -DVERSION=\"${VERSION}\"
+LDFLAGS = -g ${LIBS}
 
 # Solaris
 #CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\"
diff --git a/view.c b/view.c
index 793151d..9bd7584 100644
--- a/view.c
+++ b/view.c
@@ -32,17 +32,17 @@ pop(Client *c) {
 static void
 swap(Client *c1, Client *c2) {
 	Client tmp = *c1;
-	Client *cp = c1->prev;
-	Client *cn = c1->next;
+	Client *c1p = c1->prev;
+	Client *c1n = c1->next;
+	Client *c2p = c2->prev;
+	Client *c2n = c2->next;
 
 	*c1 = *c2;
-	c1->prev = cp;
-	c1->next = cn;
-	cp = c2->prev;
-	cn = c2->next;
 	*c2 = tmp;
-	c2->prev = cp;
-	c2->next = cn;
+	c1->prev = c1p;
+	c1->next = c1n;
+	c2->prev = c2p;
+	c2->next = c2n;
 }
 
 static void
@@ -192,10 +192,9 @@ focusprev(Arg *arg) {
 
 void
 incnmaster(Arg *arg) {
-	if(nmaster + arg->i < 1 || (wah / (nmaster + arg->i) < bh))
+	if((nmaster + arg->i < 1) || (wah / (nmaster + arg->i) < bh))
 		return;
 	nmaster += arg->i;
-
 	arrange();
 }
 
@@ -305,7 +304,9 @@ zoom(Arg *arg) {
 		n++;
 
 	c = sel;
-	if(n <= nmaster || (arrange == dofloat))
+	if(arrange == dofloat)
+		return;
+	else if(n <= nmaster)
 		pop(c);
 	else if(ismaster(sel)) {
 		if(!(c = topofstack()))
.2&id=c6fc6b173d8252d06c97af0feec200f1b7ca07d6'>^
a73a882 ^
f196b71 ^

3794c62 ^

f196b71 ^







3794c62 ^
f196b71 ^
3794c62 ^





f196b71 ^

3794c62 ^
f196b71 ^

b38905b ^
a73a882 ^
3059c9c ^
19dcbc5 ^
58beead ^
19dcbc5 ^
b60406c ^
9e4e4d9 ^

19dcbc5 ^




3059c9c ^

42fd392 ^
19dcbc5 ^



11a08b9 ^
e1811c3 ^



19dcbc5 ^



11a08b9 ^
e1811c3 ^



19dcbc5 ^
879241c ^
6d5f67a ^
42fd392 ^
19dcbc5 ^



11a08b9 ^
e1811c3 ^



19dcbc5 ^



11a08b9 ^
e1811c3 ^



19dcbc5 ^
a73a882 ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99