fix Bug #15509 HttpMessage::rewind memory leaks
authorMichael Wallner <mike@php.net>
Tue, 13 Jan 2009 09:51:45 +0000 (09:51 +0000)
committerMichael Wallner <mike@php.net>
Tue, 13 Jan 2009 09:51:45 +0000 (09:51 +0000)
http_message_object.c

index 81f31a409fdb9d46350e3707d3321f07302bbc82..88456812d7bffa33eb2f780c9b57455ce5b5cc0f 100644 (file)
@@ -393,6 +393,10 @@ void _http_message_object_free(zend_object *object TSRMLS_DC)
 {
        http_message_object *o = (http_message_object *) object;
 
+       if (o->iterator) {
+               zval_ptr_dtor(&o->iterator);
+               o->iterator = NULL;
+       }
        if (o->message) {
                http_message_dtor(o->message);
                efree(o->message);