PHP  
 PHP_5_5
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

==17075== Conditional jump or move depends on uninitialised value(s)
==17075==    at 0x4C2B537: __GI___rawmemchr (mc_replace_strmem.c:1203)
==17075==    by 0x52E671F: _IO_str_init_static_internal (in /lib64/libc-2.12.so)
==17075==    by 0x52DA6C4: vsscanf (in /lib64/libc-2.12.so)
==17075==    by 0x52D4737: sscanf (in /lib64/libc-2.12.so)
==17075==    by 0x403096: ??? (in /bin/ps)
==17075==    by 0x4022A5: ??? (in /bin/ps)
==17075==    by 0x528FD5C: (below main) (in /lib64/libc-2.12.so)
==17075== 

 

Generated at Mon, 15 Sep 2014 17:22:22 +0000 (40 hours ago)

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