]> git.wh0rd.org - tt-rss.git/commitdiff
only use posix_getpid() for debugging when possible
authorAndrew Dolgov <fox@madoka.spb.ru>
Tue, 26 Feb 2008 11:46:05 +0000 (12:46 +0100)
committerAndrew Dolgov <fox@madoka.spb.ru>
Tue, 26 Feb 2008 11:46:05 +0000 (12:46 +0100)
functions.php

index 873df424dd71f223d6bbc27293b337fe4c829277..024232e9ae012a5e172071063eb0d610d58471d2 100644 (file)
@@ -87,7 +87,9 @@
         */
        function _debug($msg) {
                $ts = strftime("%H:%M:%S", time());
-               $ts = "$ts/" . posix_getpid();
+               if (function_exists('posix_getpid')) {
+                       $ts = "$ts/" . posix_getpid();
+               }
                print "[$ts] $msg\n";
        } // function _debug