Re: [hackers] [PATCH] simplify client moving on monitor count decrease

2017-01-10 Thread Silvan Jegen
Hi Markus

On Wed, Jan 04, 2017 at 06:05:33PM +0100, Markus Teich wrote:
> ---
>  dwm.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)

Looks good to me.

I have tested this patch yesterday and today in daily use and haven't
found any issues on my 2-monitor setup (yet).


Cheers,

Silvan

 
> diff --git a/dwm.c b/dwm.c
> index 4eba952..88d49d7 100644
> --- a/dwm.c
> +++ b/dwm.c
> @@ -1896,9 +1896,8 @@ updategeom(void)
>   /* less monitors available nn < n */
>   for (i = nn; i < n; i++) {
>   for (m = mons; m && m->next; m = m->next);
> - while (m->clients) {
> + while ((c = m->clients)) {
>   dirty = 1;
> - c = m->clients;
>   m->clients = c->next;
>   detachstack(c);
>   c->mon = mons;
> -- 
> 2.10.2
> 
> 



[hackers] [PATCH] simplify client moving on monitor count decrease

2017-01-04 Thread Markus Teich
---
 dwm.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/dwm.c b/dwm.c
index 4eba952..88d49d7 100644
--- a/dwm.c
+++ b/dwm.c
@@ -1896,9 +1896,8 @@ updategeom(void)
/* less monitors available nn < n */
for (i = nn; i < n; i++) {
for (m = mons; m && m->next; m = m->next);
-   while (m->clients) {
+   while ((c = m->clients)) {
dirty = 1;
-   c = m->clients;
m->clients = c->next;
detachstack(c);
c->mon = mons;
-- 
2.10.2