diff options
author | Andrew Dolgov <[email protected]> | 2008-01-24 18:37:56 +0100 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2008-01-24 18:37:56 +0100 |
commit | abfa57fdf00894a07f8c268c799ce9b225e5bc5b (patch) | |
tree | 4fb2462ddc45e1f70c1b93f1733c041e55727209 /update_daemon2.php | |
parent | 0d6a7147e5b82cdf2c973c5efd3e5415fdc0287b (diff) | |
parent | a65a05a72e5f736cd81791fc18181a9c43f7a496 (diff) |
merge stuff
Diffstat (limited to 'update_daemon2.php')
-rw-r--r-- | update_daemon2.php | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/update_daemon2.php b/update_daemon2.php index 4d2eed5d9..cf25eeac2 100644 --- a/update_daemon2.php +++ b/update_daemon2.php @@ -61,7 +61,7 @@ } function sigalrm_handler() { - die("received SIGALRM, hang in feed update?\n"); + die("[SIGALRM] hang in feed update?\n"); } function sigchld_handler($signal) { @@ -74,7 +74,7 @@ function sigint_handler() { unlink(LOCK_DIRECTORY . "/update_daemon.lock"); - die("Received SIGINT. Exiting.\n"); + die("[SIGINT] removing lockfile and exiting.\n"); } pcntl_signal(SIGALRM, 'sigalrm_handler'); @@ -85,11 +85,6 @@ "Maybe another daemon is already running.\n"); } - if (file_is_locked("update_daemon.lock")) { - die("error: Can't create lockfile. ". - "Maybe another daemon is already running.\n"); - } - if (!pcntl_fork()) { pcntl_signal(SIGINT, 'sigint_handler'); @@ -277,7 +272,7 @@ if (DAEMON_SENDS_DIGESTS) send_headlines_digests($link); _debug("Elapsed time: " . (time() - $start_timestamp) . " second(s)"); - + db_close($link); // We are in a fork. |