Skip to content

Commit dd13c2d

Browse files
committed
Reset crash counter after long interval
Don't treat consecutive but infrequent crashes as bootloops. The bootloop recovery actions only make sense when there is no opportunity for a user to reconfigure their system. Suggested by @coderabbitai
1 parent 46f3bc0 commit dd13c2d

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

wled00/util.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -804,7 +804,11 @@ static bool detectBootLoop() {
804804
bl_crashcounter = 0;
805805
result = true;
806806
}
807-
}
807+
} else {
808+
// Reset counter on long intervals to track only consecutive short-interval crashes
809+
bl_crashcounter = 0;
810+
// TODO: crash reporting goes here
811+
}
808812
break;
809813
}
810814

0 commit comments

Comments
 (0)