diff options
author | Mikhail Gusarov <dottedmag@dottedmag.net> | 2009-05-16 02:08:46 +0700 |
---|---|---|
committer | Arnaud Fontaine <arnau@debian.org> | 2010-11-14 19:51:10 +0900 |
commit | 04003178b1f9bc0c69a6ced184fbf81e5ee7b5ad (patch) | |
tree | 6f57df0a0a81618e6acc323d3dec581c8d5f4b2f | |
parent | 9002b649f3abb48337f16480cec2cc6f5eedef70 (diff) |
Zero out handlers list in xcb_event_handlers_init
xcb_event_handle relies on the fact that handler for non-handled
event is NULL. Initialize handlers in xcb_event_handlers_init
to avoid calling function by uninitialized pointer.
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net>
Signed-off-by: Peter Harris <pharris@opentext.com>
-rw-r--r-- | event/event.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/event/event.c b/event/event.c index ce83d6e..1332a33 100644 --- a/event/event.c +++ b/event/event.c @@ -35,6 +35,7 @@ void xcb_event_handlers_init(xcb_connection_t *c, xcb_event_handlers_t *evenths) { + memset(evenths, 0, sizeof(xcb_event_handlers_t)); evenths->c = c; } |