Made Greyhound check for SimpleXML.
--- a/greyhound.php Wed Aug 06 01:06:42 2008 -0400
+++ b/greyhound.php Fri Aug 15 23:29:37 2008 -0400
@@ -95,6 +95,18 @@
exit(0);
}
+status('doing PHP capabilities check');
+if ( !function_exists('pcntl_signal') )
+{
+ warning('System does not support POSIX functions. Termination signals will result in unclean shutdown.');
+}
+
+if ( !function_exists('simplexml_load_file') )
+{
+ warning('Can\'t find support for SimpleXML, which is needed to parse the Amarok playlist file.');
+ burnout('SimpleXML required to continue. You may have an outdated version of PHP; most versions of PHP 5 have SimpleXML built-in. Check your distribution\'s documentation to find out how to enable PHP\'s SimpleXML support.');
+}
+
status('initializing playlist');
// init playlist object
@@ -108,11 +120,6 @@
try
{
status('starting PhpHttpd');
- status('doing PHP capabilities check');
- if ( !function_exists('pcntl_signal') )
- {
- warning('System does not support POSIX functions. Termination signals will result in unclean shutdown.');
- }
$httpd = new WebServer($ip, $port);
// setup handlers