From e17179daad9743344f4c128f901652d76d2fe2ba Mon Sep 17 00:00:00 2001 From: rusefi Date: Sun, 19 Mar 2017 18:49:27 -0400 Subject: [PATCH] refactoring: const --- firmware/controllers/engine_controller.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/firmware/controllers/engine_controller.cpp b/firmware/controllers/engine_controller.cpp index ae8b6c2aa1..a548b135a3 100644 --- a/firmware/controllers/engine_controller.cpp +++ b/firmware/controllers/engine_controller.cpp @@ -72,15 +72,15 @@ extern EnginePins enginePins; persistent_config_container_s persistentState CCM_OPTIONAL; -persistent_config_s *config = &persistentState.persistentConfiguration; +const persistent_config_s *config = &persistentState.persistentConfiguration; /** * todo: it really looks like these fields should become 'static', i.e. private * the whole 'extern ...' pattern is less then perfect, I guess the 'God object' Engine * would be a smaller evil. Whatever is needed should be passed into methods/modules/files as an explicit parameter. */ -engine_configuration_s *engineConfiguration = &persistentState.persistentConfiguration.engineConfiguration; -board_configuration_s *boardConfiguration = &persistentState.persistentConfiguration.engineConfiguration.bc; +const engine_configuration_s *engineConfiguration = &persistentState.persistentConfiguration.engineConfiguration; +const board_configuration_s *boardConfiguration = &persistentState.persistentConfiguration.engineConfiguration.bc; /** * CH_FREQUENCY is the number of system ticks in a second