compile-time enforcement of printf strings

This commit is contained in:
Matthew Kennedy 2024-06-10 00:56:03 -07:00
parent 6758e2dfc0
commit 2c14f4e3c1
2 changed files with 2 additions and 2 deletions

View File

@ -912,7 +912,7 @@ void resetConfigurationExt(configuration_callback_t boardCallback, engine_type_e
break;
#endif //HW_SUBARU_EG33
default:
firmwareError(ObdCode::CUSTOM_UNEXPECTED_ENGINE_TYPE, "Unexpected engine type: %d", engineType);
firmwareError(ObdCode::CUSTOM_UNEXPECTED_ENGINE_TYPE, "Unexpected engine type: %d", (int)engineType);
}
applyNonPersistentConfiguration();
}

View File

@ -21,7 +21,7 @@ public:
void append(const char *text);
void appendFast(const char *text);
void appendPrintf(const char *fmt, ...);
void appendPrintf(const char *fmt, ...) __attribute__ ((format (printf, 2, 3)));
void appendFloat(float value, int precision);
void terminate() {