Added check for PHP 5.1.0 and improved error handling for missing pcntl
authorDan
Wed, 24 Sep 2008 13:47:42 -0400
changeset 54 6d8b9497e44b
parent 53 a6b339665650
child 55 b8a3c9c54fbe
Added check for PHP 5.1.0 and improved error handling for missing pcntl
greyhound.php
--- a/greyhound.php	Wed Sep 24 13:47:23 2008 -0400
+++ b/greyhound.php	Wed Sep 24 13:47:42 2008 -0400
@@ -81,9 +81,16 @@
 }
 
 status('doing PHP capabilities check');
+
+if ( version_compare(PHP_VERSION, '5.1.0', '<') )
+{
+  burnout('The minimum required version of PHP for Greyhound is 5.1.0. PHP 5.2.x is recommended.');
+}
+
 if ( !function_exists('pcntl_signal') )
 {
-  warning('System does not support POSIX functions. Termination signals will result in unclean shutdown.');
+  warning('System does not support POSIX functions. Termination signals will result in unclean shutdown and multi-process webserving will not work.');
+  $allow_fork = false;
 }
 
 if ( !function_exists('simplexml_load_file') )