summaryrefslogtreecommitdiffstats
path: root/movement
diff options
context:
space:
mode:
Diffstat (limited to 'movement')
-rw-r--r--movement/watch_faces/thermistor/thermistor_logging_face.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/movement/watch_faces/thermistor/thermistor_logging_face.c b/movement/watch_faces/thermistor/thermistor_logging_face.c
index 5351ce88..3e9e62b3 100644
--- a/movement/watch_faces/thermistor/thermistor_logging_face.c
+++ b/movement/watch_faces/thermistor/thermistor_logging_face.c
@@ -50,8 +50,10 @@ void _thermistor_logging_face_update_display(thermistor_logger_state_t *logger_s
void thermistor_logging_face_setup(movement_settings_t *settings, void ** context_ptr) {
(void) settings;
- if (*context_ptr == NULL) *context_ptr = malloc(sizeof(thermistor_logger_state_t));
- memset(*context_ptr, 0, sizeof(thermistor_logger_state_t));
+ if (*context_ptr == NULL) {
+ *context_ptr = malloc(sizeof(thermistor_logger_state_t));
+ memset(*context_ptr, 0, sizeof(thermistor_logger_state_t));
+ }
}
void thermistor_logging_face_activate(movement_settings_t *settings, void *context) {