Permalink
Browse files

Merge pull request #19 from pajaco/no-posix

Removed dependency on posix module; replaced posix_getpid with getmypi
  • Loading branch information...
2 parents 8a689d3 + 6c47441 commit 8427a3cd8a2cb8f8f0d85faf0bd9d49b10961a04 @jamesgpearce jamesgpearce committed May 14, 2014
Showing with 3 additions and 3 deletions.
  1. +3 −3 src/phpsh.php
View
@@ -34,7 +34,7 @@
exit;
}
-$missing = array_diff(array('pcre','posix','tokenizer'),
+$missing = array_diff(array('pcre','tokenizer'),
get_loaded_extensions());
if ($missing) {
fwrite(STDERR, 'Fatal error: phpsh requires the following extensions: '.
@@ -581,7 +581,7 @@ function interactive_loop() {
}
if ($this->fork_every_command) {
- $parent_pid = posix_getpid();
+ $parent_pid = getmypid();
$pid = pcntl_fork();
$evalue = null;
if ($pid) {
@@ -598,7 +598,7 @@ function interactive_loop() {
}
// if we are still alive..
- $childpid = posix_getpid();
+ $childpid = getmypid();
fwrite($this->_comm_handle, "child $childpid\n");
}
} else {

0 comments on commit 8427a3c

Please sign in to comment.