Use explicit pointer casting for c++ compatibility (#826)

This commit is contained in:
Aureus 2020-06-01 18:21:27 -04:00 committed by GitHub
parent 4152bfce7c
commit c726723545
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -121,12 +121,12 @@ static void redisLibevCleanup(void *privdata) {
static void redisLibevTimeout(EV_P_ ev_timer *timer, int revents) { static void redisLibevTimeout(EV_P_ ev_timer *timer, int revents) {
((void)revents); ((void)revents);
redisLibevEvents *e = timer->data; redisLibevEvents *e = (redisLibevEvents*)timer->data;
redisAsyncHandleTimeout(e->context); redisAsyncHandleTimeout(e->context);
} }
static void redisLibevSetTimeout(void *privdata, struct timeval tv) { static void redisLibevSetTimeout(void *privdata, struct timeval tv) {
redisLibevEvents *e = privdata; redisLibevEvents *e = (redisLibevEvents*)privdata;
struct ev_loop *loop = e->loop; struct ev_loop *loop = e->loop;
((void)loop); ((void)loop);