]> git.wh0rd.org - tt-rss.git/commitdiff
tweak daemon hang detection
authorAndrew Dolgov <fox@madoka.spb.ru>
Thu, 4 Oct 2007 05:44:13 +0000 (06:44 +0100)
committerAndrew Dolgov <fox@madoka.spb.ru>
Thu, 4 Oct 2007 05:44:13 +0000 (06:44 +0100)
functions.php

index 45c59d37efca7544550a3a0181983ef53b3df2f6..e218a6c2846b6dcb9716d3108040b7cf17e0d2fd 100644 (file)
                        print "<param key=\"daemon_is_running\" value=\"".
                                sprintf("%d", file_is_locked("update_daemon.lock")) . "\"/>";
 
-                       if (time() - $_SESSION["daemon_stamp_check"] > 600) {
+                       if (time() - $_SESSION["daemon_stamp_check"] > 30) {
 
                                $stamp = (int)read_stampfile("update_daemon.stamp");
 
-//                             $stamp_delta = time() - $stamp;
 //                             print "<param key=\"daemon_stamp_delta\" value=\"$stamp_delta\"/>";
 
                                if ($stamp) {
-                                       if (time() - $stamp > 3600*3) {
+                                       $stamp_delta = time() - $stamp;
+
+                                       if ($stamp_delta > 1800) {
                                                $stamp_check = 0;
                                        } else {
                                                $stamp_check = 1;