diff --git a/ChangeLog b/ChangeLog index feeba53a..cb263026 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,7 @@ Changes in 1.4.13-stable: o Do not drop data from evbuffer when out of memory; reported by Jacek Masiulaniec o Rename our replacement compat/sys/_time.h header to avoid build a conflict on HPUX; reported by Kathryn Hogg. o Build kqueue.c correctly on GNU/kFreeBSD platforms. Patch pulled upstream from Debian. + o Fix a problem with excessive memory allocation when using multiple event priorities. Changes in 1.4.12-stable: diff --git a/event.c b/event.c index ce57a221..7bfdceb0 100644 --- a/event.c +++ b/event.c @@ -326,8 +326,8 @@ event_base_priority_init(struct event_base *base, int npriorities) /* Allocate our priority queues */ base->nactivequeues = npriorities; - base->activequeues = (struct event_list **)calloc(base->nactivequeues, - npriorities * sizeof(struct event_list *)); + base->activequeues = (struct event_list **) + calloc(base->nactivequeues, sizeof(struct event_list *)); if (base->activequeues == NULL) event_err(1, "%s: calloc", __func__);