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/posix/tests/posix_kill_basic.phpt ('Test posix_kill(), posix_get_last_error and posix_strerror() functions : basic functionality')

Script

1: <?php 
2:   
echo "Basic test of POSIX getpgid(), kill(), get_last_error() and strerror() functions\n"
3:       
4:       
// Don't rely on PCNTL extension being around
5:       
$SIGKILL 9;
6:       
7:       
// TODO Once we have PS open working beef up this test to create a process and kill it
8:       // for now start at a low pid and find first pid which does not exist.
9:       
$pid 999;
10:       do {
11:           
$pid += 1;       
12:           
$result shell_exec("ps -p " $pid);
13:     } while (
stripos($result, (string)$pid) != FALSE); 
14:       
15:       echo 
"Kill pid=" $pid "\n";
16:     
var_dump(posix_kill($pid,$SIGKILL));
17:     
18:     
$errno posix_get_last_error(); 
19:     
20:     
var_dump($errno);
21:     
var_dump(posix_strerror($errno));
22:     
23:
?>
24:
===DONE====
25:

Report

==13398== Conditional jump or move depends on uninitialised value(s)
==13398==    at 0x4C2CDF7: __GI___rawmemchr (vg_replace_strmem.c:1242)
==13398==    by 0x52E870F: _IO_str_init_static_internal (in /lib64/libc-2.12.so)
==13398==    by 0x52DC6B4: vsscanf (in /lib64/libc-2.12.so)
==13398==    by 0x52D6727: sscanf (in /lib64/libc-2.12.so)
==13398==    by 0x4031B6: ??? (in /bin/ps)
==13398==    by 0x402335: ??? (in /bin/ps)
==13398==    by 0x5291D5C: (below main) (in /lib64/libc-2.12.so)
==13398== 

 

Generated at Mon, 31 Aug 2015 13:36:01 +0000 (2 days ago)

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