- fix read beyond end of key string for var_dump() and fellows
authorMichael Wallner <mike@php.net>
Fri, 9 Dec 2005 11:52:36 +0000 (11:52 +0000)
committerMichael Wallner <mike@php.net>
Fri, 9 Dec 2005 11:52:36 +0000 (11:52 +0000)
http_message_object.c

index f741e65754ea7bdeebe2976d9c9861ff985444c9..b84bdfbbc88626d500ca3584eaacbea817f9e91a 100644 (file)
@@ -476,7 +476,7 @@ static HashTable *_http_message_object_get_props(zval *object TSRMLS_DC)
                char *m_prop_name; \
                int m_prop_len; \
                zend_mangle_property_name(&m_prop_name, &m_prop_len, "*", 1, name, lenof(name), 0); \
-               add_assoc_ ##ptype## _ex(&array, m_prop_name, sizeof(name)+4, val); \
+               add_assoc_ ##ptype## _ex(&array, m_prop_name, sizeof(name)+3, val); \
                efree(m_prop_name); \
        }
 #define ASSOC_STRING(array, name, val) ASSOC_STRINGL(array, name, val, strlen(val))
@@ -485,7 +485,7 @@ static HashTable *_http_message_object_get_props(zval *object TSRMLS_DC)
                char *m_prop_name; \
                int m_prop_len; \
                zend_mangle_property_name(&m_prop_name, &m_prop_len, "*", 1, name, lenof(name), 0); \
-               add_assoc_stringl_ex(&array, m_prop_name, sizeof(name)+4, val, len, 1); \
+               add_assoc_stringl_ex(&array, m_prop_name, sizeof(name)+3, val, len, 1); \
                efree(m_prop_name); \
        }