- don't copy the refcount of the passed in value -- fixes remaining mem-leaks of...
[m6w6/ext-http] / missing.c
index fea611c8eb5718f86ed3a05d51b0d724ccfdc8a4..3e7dbfabb1c2cff7a3940b4f0d55c5eb105a2bda 100644 (file)
--- a/missing.c
+++ b/missing.c
@@ -38,7 +38,6 @@ static inline zval *tmp_zval(void)
 
 static void dup_zval(zval **z)
 {
-       zval *o = *z;
        zval_add_ref(z);
        SEPARATE_ZVAL(z);
 }
@@ -141,8 +140,7 @@ int zend_update_static_property(zend_class_entry *scope, char *name, size_t name
                                zval_copy_ctor(*property);
                        }
                } else {
-                       **property = *value;
-                       zval_copy_ctor(*property);
+                       REPLACE_ZVAL_VALUE(property, value, 1);
                }
                retval = SUCCESS;
        }