X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Fevent.c;h=69b63ff1334887c766dac083e0eab748d7824bd4;hb=8470142e00a25553e5a77393b1b4727c0542bc65;hp=3448194ef022813e49b95a8273c4060a96db5f0b;hpb=d56e90fac8e821f3773372e9342d60de169963b9;p=chaz%2Fopenbox diff --git a/openbox/event.c b/openbox/event.c index 3448194e..69b63ff1 100644 --- a/openbox/event.c +++ b/openbox/event.c @@ -438,6 +438,8 @@ static void event_handle_client(Client *client, XEvent *e) client_unmanage(client); break; case MapRequest: + if (!client->iconic) break; /* this normally doesn't happen, but if it + does, we don't want it! */ if (screen_showing_desktop) screen_show_desktop(FALSE); client_iconify(client, FALSE, TRUE); @@ -483,7 +485,9 @@ static void event_handle_client(Client *client, XEvent *e) } e->xclient = ce.xclient; } - client_set_desktop(client, e->xclient.data.l[0]); + if (e->xclient.data.l[0] >= 0 && + e->xclient.data.l[0] < screen_num_desktops) + client_set_desktop(client, e->xclient.data.l[0]); } else if (msgtype == prop_atoms.net_wm_state) { /* can't compress these */ g_message("net_wm_state %s %ld %ld for 0x%lx",