]> granicus.if.org Git - php/commitdiff
Nuke compiler warning
authorKalle Sommer Nielsen <kalle@php.net>
Wed, 13 May 2009 15:54:48 +0000 (15:54 +0000)
committerKalle Sommer Nielsen <kalle@php.net>
Wed, 13 May 2009 15:54:48 +0000 (15:54 +0000)
ext/phar/func_interceptors.c

index cb087302337800b6fd607d340115525d772e867a..cddd7a0933ce3b5f76b0a20a2dcc78254c353f5f 100644 (file)
@@ -98,7 +98,7 @@ PHAR_FUNC(phar_file_get_contents) /* {{{ */
        char *contents;
        zend_bool use_include_path = 0;
        php_stream *stream;
-       int len, newlen;
+       int len;
        long offset = -1;
        long maxlen = PHP_STREAM_COPY_ALL;
        zval *zcontext = NULL;
@@ -205,6 +205,7 @@ phar_it:
                        if ((len = php_stream_copy_to_mem(stream, &contents, maxlen, 0)) > 0) {
 #if PHP_MAJOR_VERSION < 6
                                if (PG(magic_quotes_runtime)) {
+                                       int newlen;
                                        contents = php_addslashes(contents, len, &newlen, 1 TSRMLS_CC); /* 1 = free source string */
                                        len = newlen;
                                }