sunrise_sunset_face: Fix use of uninitialized memory.
This was causing a crash in the simulator when setting the location. Fixes: #198
This commit is contained in:
parent
c4a5cb463e
commit
1f6409a71c
@ -197,6 +197,8 @@ static void _sunrise_sunset_face_update_settings_display(movement_event_t event,
|
|||||||
char buf[12];
|
char buf[12];
|
||||||
|
|
||||||
switch (state->page) {
|
switch (state->page) {
|
||||||
|
case 0:
|
||||||
|
return;
|
||||||
case 1:
|
case 1:
|
||||||
sprintf(buf, "LA %c %04d", state->working_latitude.sign ? '-' : '+', abs(_sunrise_sunset_face_latlon_from_struct(state->working_latitude)));
|
sprintf(buf, "LA %c %04d", state->working_latitude.sign ? '-' : '+', abs(_sunrise_sunset_face_latlon_from_struct(state->working_latitude)));
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user