Skip to content

Commit

Permalink
Merge 'fix-sunrise-sunset-uninitialized'
Browse files Browse the repository at this point in the history
Fixes a crash due to use of uninitialized buffer when setting location.

Reported-by: eshrh <[email protected]>
Fixed-by: Wesley Aptekar-Cassels <[email protected]>
Reviewed-by: Matheus Afonso Martins Moreira <[email protected]>
Tested-by: Matheus Afonso Martins Moreira <[email protected]>
Tested-on-hardware-by: Matheus Afonso Martins Moreira <[email protected]>
Signed-off-by: Matheus Afonso Martins Moreira <[email protected]>
GitHub-Pull-Request: joeycastillo#329
GitHub-Issue: joeycastillo#198
Fixes: joeycastillo#198
  • Loading branch information
matheusmoreira committed Mar 8, 2024
2 parents af18673 + 1f6409a commit a4ee7dd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions movement/watch_faces/complication/sunrise_sunset_face.c
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,8 @@ static void _sunrise_sunset_face_update_settings_display(movement_event_t event,
char buf[12];

switch (state->page) {
case 0:
return;
case 1:
sprintf(buf, "LA %c %04d", state->working_latitude.sign ? '-' : '+', abs(_sunrise_sunset_face_latlon_from_struct(state->working_latitude)));
break;
Expand Down

0 comments on commit a4ee7dd

Please sign in to comment.