diff --git a/src/window.c b/src/window.c index 8ef3880..eed7d56 100644 --- a/src/window.c +++ b/src/window.c @@ -2048,7 +2048,7 @@ addWindow (CompScreen *screen, w->desktop); if (w->desktop != 0xffffffff) { - if (w->desktop < 0 || w->desktop >= screen->nDesktop) + if (w->desktop >= screen->nDesktop) w->desktop = screen->currentDesktop; } @@ -4745,7 +4745,7 @@ setDesktopForWindow (CompWindow *w, if (w->type & (CompWindowTypeDesktopMask | CompWindowTypeDockMask)) return; - if (desktop < 0 || desktop >= w->screen->nDesktop) + if (desktop >= w->screen->nDesktop) return; }