[client] Send properly the ClientMessage request when killing a client

This commit is contained in:
Arnaud Fontaine 2008-03-28 13:48:05 +00:00 committed by Julien Danjou
parent d2383012f7
commit b0b0dcf525
1 changed files with 5 additions and 0 deletions

View File

@ -960,8 +960,13 @@ client_kill(Client *c)
if(client_isprotodel(globalconf.connection, c->win))
{
/* Initialize all of event's fields first */
memset(&ev, 0, sizeof(ev));
ev.response_type = XCB_CLIENT_MESSAGE;
ev.window = c->win;
ev.type = xutil_intern_atom(globalconf.connection, "WM_PROTOCOLS");
ev.format = 32;
ev.data.data32[0] = xutil_intern_atom(globalconf.connection, "WM_DELETE_WINDOW");
ev.data.data32[1] = XCB_CURRENT_TIME;