AP_KDECAN: use NEW_NOTHROW for new(std::nothrow)

This commit is contained in:
Andrew Tridgell 2024-05-27 11:24:12 +10:00
parent 6962c4080d
commit 98697ba5d3
1 changed files with 1 additions and 1 deletions

View File

@ -63,7 +63,7 @@ void AP_KDECAN::init()
for (uint8_t i = 0; i < HAL_NUM_CAN_IFACES; i++) {
if (CANSensor::get_driver_type(i) == AP_CAN::Protocol::KDECAN) {
_driver = new AP_KDECAN_Driver();
_driver = NEW_NOTHROW AP_KDECAN_Driver();
return;
}
}