ext/god/kqueue_handler.c in god-0.7.5 vs ext/god/kqueue_handler.c in god-0.7.6
- old
+ new
@@ -78,9 +78,10 @@
}
nevents = kevent(kq, NULL, 0, events, num_to_fetch, NULL);
if (-1 == nevents) {
+ free(events);
rb_raise(rb_eStandardError, strerror(errno));
} else {
for (i = 0; i < nevents; i++) {
if (events[i].fflags & NOTE_EXIT) {
rb_funcall(cEventHandler, m_call, 2, INT2NUM(events[i].ident), ID2SYM(proc_exit));