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

==1634== Conditional jump or move depends on uninitialised value(s)
==1634==    at 0xF20786: zend_send_by_var_helper_SPEC_VAR (zend_vm_execute.h:13379)
==1634==    by 0xF21D91: ZEND_SEND_VAR_SPEC_VAR_HANDLER (zend_vm_execute.h:13495)
==1634==    by 0xED4ACA: execute_ex (zend_vm_execute.h:363)
==1634==    by 0xED566D: zend_execute (zend_vm_execute.h:388)
==1634==    by 0xE6A4DB: zend_execute_scripts (zend.c:1344)
==1634==    by 0xD88C49: php_execute_script (main.c:2584)
==1634==    by 0x101D0B6: do_cli (php_cli.c:994)
==1634==    by 0x101E863: main (php_cli.c:1378)
==1634== 
==1634== Conditional jump or move depends on uninitialised value(s)
==1634==    at 0xE6DC90: zend_parse_arg_impl (zend_API.c:443)
==1634==    by 0xE6F3D4: zend_parse_arg (zend_API.c:691)
==1634==    by 0xE70020: zend_parse_va_args (zend_API.c:873)
==1634==    by 0xE704FD: zend_parse_parameters (zend_API.c:924)
==1634==    by 0xE8B2D0: zif_strlen (zend_builtin_functions.c:486)
==1634==    by 0xED7044: zend_do_fcall_common_helper_SPEC (zend_vm_execute.h:558)
==1634==    by 0xEE2B45: ZEND_DO_FCALL_SPEC_CONST_HANDLER (zend_vm_execute.h:2595)
==1634==    by 0xED4ACA: execute_ex (zend_vm_execute.h:363)
==1634==    by 0xED566D: zend_execute (zend_vm_execute.h:388)
==1634==    by 0xE6A4DB: zend_execute_scripts (zend.c:1344)
==1634==    by 0xD88C49: php_execute_script (main.c:2584)
==1634==    by 0x101D0B6: do_cli (php_cli.c:994)
==1634== 

 

Generated at Wed, 10 Dec 2014 19:30:08 +0000 (9 days ago)

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