Merge R_2_5
[m6w6/ext-http] / php_http_encoding.c
index 1ef355e817d1e4ce75b379b65b496ed9567ebb2b..e7557a0852c0daeea1679ee837d5cda13c490727 100644 (file)
@@ -634,7 +634,7 @@ static ZEND_RESULT_CODE dechunk_update(php_http_encoding_stream_t *s, const char
                                        /*      if strtoul() stops at the beginning of the buffered data
                                                there's something oddly wrong, i.e. bad input */
                                        if (stop == ctx->buffer.data) {
-                                               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed to parse chunk len from '%.*s'", (int) MIN(16, ctx->buffer.used), ctx->buffer.data);
+                                               php_error_docref(NULL, E_WARNING, "Failed to parse chunk len from '%.*s'", (int) MIN(16, ctx->buffer.used), ctx->buffer.data);
                                                php_http_buffer_dtor(&tmp);
                                                return FAILURE;
                                        }
@@ -909,7 +909,7 @@ php_http_encoding_stream_object_t *php_http_encoding_stream_object_new_ex(zend_c
 {
        php_http_encoding_stream_object_t *o;
 
-       o = ecalloc(1, sizeof(*o) + (ce->default_properties_count - 1) * sizeof(zval));
+       o = ecalloc(1, sizeof(*o) + zend_object_properties_size(ce));
        zend_object_std_init(&o->zo, ce);
        object_properties_init(&o->zo, ce);