aboutsummaryrefslogtreecommitdiffstats
path: root/xutil.c
diff options
context:
space:
mode:
authorokan2013-05-27 23:20:45 +0000
committerokan2013-05-27 23:20:45 +0000
commit806eaefbddc237cd544a9f1aa3715f3c429e08ae (patch)
tree2315debc4615c03aaaebf55768e5caa58188fdf7 /xutil.c
parent0e1a282d21c537a3a9f065464a15044befb6f4d1 (diff)
downloadcwm-806eaefbddc237cd544a9f1aa3715f3c429e08ae.tar.gz
fix type in a ClientMessage (xu_sendmsg).
Diffstat (limited to 'xutil.c')
-rw-r--r--xutil.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/xutil.c b/xutil.c
index b610659..719afa8 100644
--- a/xutil.c
+++ b/xutil.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: xutil.c,v 1.67 2013/05/23 16:52:39 okan Exp $
+ * $OpenBSD: xutil.c,v 1.68 2013/05/27 23:20:45 okan Exp $
*/
#include <sys/param.h>
@@ -125,19 +125,19 @@ xu_configure(struct client_ctx *cc)
}
void
-xu_sendmsg(Window win, Atom atm, long val)
+xu_sendmsg(Window win, Atom type, Atom atm)
{
- XEvent e;
+ XClientMessageEvent e;
- (void)memset(&e, 0, sizeof(e));
- e.xclient.type = ClientMessage;
- e.xclient.window = win;
- e.xclient.message_type = atm;
- e.xclient.format = 32;
- e.xclient.data.l[0] = val;
- e.xclient.data.l[1] = CurrentTime;
+ bzero(&e, sizeof(e));
+ e.type = ClientMessage;
+ e.window = win;
+ e.message_type = type;
+ e.format = 32;
+ e.data.l[0] = atm;
+ e.data.l[1] = CurrentTime;
- XSendEvent(X_Dpy, win, False, 0, &e);
+ XSendEvent(X_Dpy, win, False, 0L, (XEvent *)&e);
}
int