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

==10513== Conditional jump or move depends on uninitialised value(s)
==10513==    at 0x4C2B537: __GI___rawmemchr (mc_replace_strmem.c:1203)
==10513==    by 0x52E670F: _IO_str_init_static_internal (in /lib64/libc-2.12.so)
==10513==    by 0x52DA6B4: vsscanf (in /lib64/libc-2.12.so)
==10513==    by 0x52D4727: sscanf (in /lib64/libc-2.12.so)
==10513==    by 0x4031B6: ??? (in /bin/ps)
==10513==    by 0x402335: ??? (in /bin/ps)
==10513==    by 0x528FD5C: (below main) (in /lib64/libc-2.12.so)
==10513== 

 

Generated at Thu, 18 Dec 2014 07:17:56 +0000 (43 hours ago)

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