Merged endless loop fix from stable
This commit is contained in:
+2
-2
@@ -252,7 +252,7 @@ function stats_cron_weekly () {
|
||||
|
||||
$weeks = 0;
|
||||
mtrace("starting at $timestart");
|
||||
while ($sunday >= $nextsunday) {
|
||||
while ($sunday > $nextsunday && $timestart < $nextsunday) {
|
||||
|
||||
$timesql = " (timeend > $timestart AND timeend < $nextsunday) ";
|
||||
begin_sql();
|
||||
@@ -381,7 +381,7 @@ function stats_cron_monthly () {
|
||||
|
||||
$months = 0;
|
||||
mtrace("starting from $timestart");
|
||||
while ($monthend >= $nextmonthend) {
|
||||
while ($monthend > $nextmonthend && $timestart < $nextmonthend) {
|
||||
|
||||
$timesql = " (timeend > $timestart AND timeend < $nextmonthend) ";
|
||||
begin_sql();
|
||||
|
||||
Reference in New Issue
Block a user