]> git.mxchange.org Git - friendica.git/blobdiff - include/cronhooks.php
Cron/Queue: Setting a limit to avoid endless PHP jobs.
[friendica.git] / include / cronhooks.php
index cf1d13765faf56d8d55b49bc5d6796cc677ede02..d5daf0d7d447a2beb4bb7a769872dd3b410b6dbf 100644 (file)
@@ -50,11 +50,14 @@ function cronhooks_run(&$argv, &$argc){
 
        logger('cronhooks: start');
 
-
        $d = datetime_convert();
 
+       set_time_limit(9*60*60); // Setting the maximum execution time for cronjobs to 9 minutes.
+
        call_hooks('cron', $d);
 
+       logger('cronhooks: end');
+
        return;
 }