Skip to content

Commit 937dc34

Browse files
authored
Merge pull request #324 from MFAshby/fix_stop_crash_315
Fix stopwatch crash after stop pressed
2 parents e3ead33 + 3a93823 commit 937dc34

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/displayapp/screens/StopWatch.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,9 @@ bool StopWatch::Refresh() {
115115
// Init state when an user first opens the app
116116
// and when a stop/reset button is pressed
117117
case States::Init: {
118-
if (btnStopLap) {
118+
if (btnStopLap != nullptr) {
119119
lv_obj_del(btnStopLap);
120+
btnStopLap = nullptr;
120121
}
121122
// The initial default value
122123
lv_label_set_text(time, "00:00");

0 commit comments

Comments
 (0)