PHP  
 PHP_5_6
downloads | QA | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
 

Valgrind Report for ext/zip/tests/oo_properties.phpt ('ziparchive::properties isset()/empty() checks')

Script

1: <?php
2:
3: $dirname 
dirname(__FILE__) . '/';
4:
$file $dirname '__property_test.zip';
5:
6:
copy($dirname 'test_with_comment.zip'$file);
7:
8:
$zip = new ZipArchive;
9: if (!
$zip->open($file)) {
10:     exit(
'failed');
11: }
12:
13:
printf("zip->status (%d):\n\tempty(): %d\n\tisset(): %d\n"$zip->status, empty($zip->status), isset($zip->status));
14:
printf("zip->numFiles (%d):\n\tempty(): %d\n\tisset(): %d\n"$zip->numFiles, empty($zip->numFiles), isset($zip->numFiles));
15:
printf("zip->bogus (%d):\n\tempty(): %d\n\tisset(): %d\n"$zip->bogus, empty($zip->bogus), isset($zip->bogus));
16:
17:
18:
$zip->addEmptyDir('emptydir');
19:
20:
printf("zip->status (%d):\n\tempty(): %d\n\tisset(): %d\n"$zip->status, empty($zip->status), isset($zip->status));
21:
printf("zip->numFiles (%d):\n\tempty(): %d\n\tisset(): %d\n"$zip->numFiles, empty($zip->numFiles), isset($zip->numFiles));
22:
printf("zip->filename (%d):\n\tempty(): %d\n\tisset(): %d\n"strlen($zip->filename), empty($zip->filename), isset($zip->filename));
23:
printf("zip->comment (%d):\n\tempty(): %d\n\tisset(): %d\n"strlen($zip->comment), empty($zip->comment), isset($zip->comment));
24:
25: unset(
$zip); //close the file before unlinking
26:
@unlink($file);
27:
?>
28:

Report

==1276== Conditional jump or move depends on uninitialised value(s)
==1276==    at 0xF74A45: zend_send_by_var_helper_SPEC_VAR (zend_vm_execute.h:13382)
==1276==    by 0xF76050: ZEND_SEND_VAR_SPEC_VAR_HANDLER (zend_vm_execute.h:13498)
==1276==    by 0xF28D16: execute_ex (zend_vm_execute.h:363)
==1276==    by 0xF298B9: zend_execute (zend_vm_execute.h:388)
==1276==    by 0xEBE657: zend_execute_scripts (zend.c:1341)
==1276==    by 0xDDC5FF: php_execute_script (main.c:2597)
==1276==    by 0x1075F6E: do_cli (php_cli.c:994)
==1276==    by 0x107771B: main (php_cli.c:1378)
==1276== 
==1276== Conditional jump or move depends on uninitialised value(s)
==1276==    at 0xEC1E0C: zend_parse_arg_impl (zend_API.c:443)
==1276==    by 0xEC3550: zend_parse_arg (zend_API.c:691)
==1276==    by 0xEC419C: zend_parse_va_args (zend_API.c:873)
==1276==    by 0xEC4679: zend_parse_parameters (zend_API.c:924)
==1276==    by 0xEDF4D4: zif_strlen (zend_builtin_functions.c:486)
==1276==    by 0xF2B290: zend_do_fcall_common_helper_SPEC (zend_vm_execute.h:558)
==1276==    by 0xF36DFC: ZEND_DO_FCALL_SPEC_CONST_HANDLER (zend_vm_execute.h:2599)
==1276==    by 0xF28D16: execute_ex (zend_vm_execute.h:363)
==1276==    by 0xF298B9: zend_execute (zend_vm_execute.h:388)
==1276==    by 0xEBE657: zend_execute_scripts (zend.c:1341)
==1276==    by 0xDDC5FF: php_execute_script (main.c:2597)
==1276==    by 0x1075F6E: do_cli (php_cli.c:994)
==1276== 

 

Generated at Thu, 25 Jun 2015 08:17:01 +0000 (5 days ago)

Copyright © 2005-2015 The PHP Group
All rights reserved.