From: Martin Mares Date: Tue, 7 Feb 2012 09:10:11 +0000 (+0100) Subject: Main: Fixed miscalculated memory allocation X-Git-Tag: v5.0~94 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=69492f375d4700edd9e309ebc57b5438d38f903f;p=libucw.git Main: Fixed miscalculated memory allocation --- diff --git a/ucw/mainloop.c b/ucw/mainloop.c index c7fe0125..454ea81c 100644 --- a/ucw/mainloop.c +++ b/ucw/mainloop.c @@ -100,7 +100,7 @@ main_new(void) m->epoll_fd = epoll_create(64); if (m->epoll_fd < 0) die("epoll_create() failed: %m"); - m->epoll_events = xmalloc(EPOLL_BUF_SIZE * sizeof(struct epoll_event *)); + m->epoll_events = xmalloc(EPOLL_BUF_SIZE * sizeof(struct epoll_event)); clist_init(&m->file_recalc_list); #else m->poll_table_obsolete = 1;