mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-31 02:16:53 +08:00
kinetis:Fixed hard fault when called with nullptr for errata
Logger was hard faulting on start due to a write to null pointer dereferece of errata
This commit is contained in:
@@ -55,7 +55,10 @@ int board_mcu_version(char *rev, const char **revstr, const char **errata)
|
||||
chip[CHIP_TAG_LEN - 1] = '0' + ((sim_sdid & SIM_SDID_SUBFAMID_MASK) >> SIM_SDID_SUBFAMID_SHIFT);
|
||||
*revstr = chip;
|
||||
*rev = '0' + ((sim_sdid & SIM_SDID_REVID_MASK) >> SIM_SDID_REVID_SHIFT);
|
||||
*errata = NULL;
|
||||
|
||||
if (errata) {
|
||||
*errata = NULL;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user