diff --git a/libraries/AP_CANManager/LogStructure.h b/libraries/AP_CANManager/LogStructure.h index 3f2e2c33cc..502f3f38c2 100644 --- a/libraries/AP_CANManager/LogStructure.h +++ b/libraries/AP_CANManager/LogStructure.h @@ -56,9 +56,7 @@ struct PACKED log_CAFD { uint64_t data[8]; }; -#if !AP_CAN_LOGGING_ENABLED -#define LOG_STRUCTURE_FROM_CANMANAGER -#else +#if AP_CAN_LOGGING_ENABLED #define LOG_STRUCTURE_FROM_CANMANAGER \ { LOG_CANF_MSG, sizeof(log_CANF), \ "CANF", \ @@ -76,4 +74,6 @@ struct PACKED log_CAFD { "F" "-" "-" "-" "-" "-" "-" "-" "-" "-" "-" "-", \ false \ }, +#else +#define LOG_STRUCTURE_FROM_CANMANAGER #endif // AP_CAN_LOGGING_ENABLED