libratbox: Fix sizeof in two memsets.

This fixes a compiler warning. The necessary fields of the struct sigevent
were initialized so there was no problem.

Submitted by:	Aaron (via IRC)
Reviewed by:	Attila
This commit is contained in:
Jilles Tjoelker 2015-01-15 23:36:26 +01:00
parent 1c864688bb
commit 7db54a1f97
2 changed files with 2 additions and 2 deletions

View file

@ -405,7 +405,7 @@ rb_epoll_sched_event_signalfd(struct ev_entry *event, int when)
struct sigevent ev;
struct itimerspec ts;
memset(&ev, 0, sizeof(&ev));
memset(&ev, 0, sizeof(ev));
event->comm_ptr = rb_malloc(sizeof(timer_t));
id = event->comm_ptr;
ev.sigev_notify = SIGEV_SIGNAL;

View file

@ -412,7 +412,7 @@ rb_sigio_sched_event(struct ev_entry *event, int when)
if(can_do_event <= 0)
return 0;
memset(&ev, 0, sizeof(&ev));
memset(&ev, 0, sizeof(ev));
event->comm_ptr = rb_malloc(sizeof(timer_t));
id = event->comm_ptr;
ev.sigev_notify = SIGEV_SIGNAL;