Re-implement XClientMessage handling so that we can feed screen_find and

client_find valid resources as needed, relieving the need for
screen_find to ungracefully handle invalid root windows. Removes a long
standing XXX.  Should theoretically allow XClientMessage handling on
more than one X screen.  Alter callers of screen_find to handle
failures.
This commit is contained in:
okan
2015-06-30 14:01:43 +00:00
parent 9ea5f25347
commit 8515d717ae
3 changed files with 46 additions and 41 deletions

View File

@@ -55,7 +55,8 @@ client_init(Window win, struct screen_ctx *sc)
return(NULL);
if (sc == NULL) {
sc = screen_find(wattr.root);
if ((sc = screen_find(wattr.root)) == NULL)
return(NULL);
mapped = 1;
} else {
if (wattr.override_redirect || wattr.map_state != IsViewable)