From 28dbd5551ee75e843019e6f067ed069daaabba0b Mon Sep 17 00:00:00 2001 From: Olivier Brunel Date: Fri, 10 Jan 2014 16:25:14 +0100 Subject: Update the event callback Instead of using two void* arguments for all events, we now send one pointer to an alpm_event_t struct. This contains the type of event that was triggered. With this information, the pointer can then be typecasted to the event-specific struct in order to get additional arguments. Signed-off-by: Olivier Brunel Signed-off-by: Allan McRae --- lib/libalpm/handle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/libalpm/handle.h') diff --git a/lib/libalpm/handle.h b/lib/libalpm/handle.h index e11d82a1..db42e8ca 100644 --- a/lib/libalpm/handle.h +++ b/lib/libalpm/handle.h @@ -31,10 +31,10 @@ #include #endif -#define EVENT(h, e, d1, d2) \ +#define EVENT(h, e) \ do { \ if((h)->eventcb) { \ - (h)->eventcb(e, d1, d2); \ + (h)->eventcb((alpm_event_t *) (e)); \ } \ } while(0) #define QUESTION(h, q, d1, d2, d3, r) \ -- cgit v1.2.3-24-g4f1b