Commits

Ruslan Osmanov committed cb9a1b9

Fix: heap corruption in bevent callbacks

Comments (0)

Files changed (1)

classes/buffer_event.c

 
 		if (bev->self) {
 			args[0] = &bev->self;
-			/*Z_ADDREF_P(bev->self);*/
+			Z_ADDREF_P(bev->self);
 		}
 		if (arg_data) {
 			Z_ADDREF_P(arg_data);
 	if (ZEND_FCI_INITIALIZED(*pfci)) {
 		/* Setup callback args */
 		args[0] = &bev->self;
-		/*Z_ADDREF_P(bev->self);*/
+		Z_ADDREF_P(bev->self);
 
 		MAKE_STD_ZVAL(arg_events);
 		ZVAL_LONG(arg_events, events);