Fix missing string terminator for CLI map command defaults output

This commit is contained in:
Bruce Luckcuck 2018-10-31 16:16:38 -04:00
parent a18d48f533
commit 13a365dd35
1 changed files with 4 additions and 1 deletions

View File

@ -2616,7 +2616,10 @@ static void printMap(uint8_t dumpMask, const rxConfig_t *rxConfig, const rxConfi
buf[i] = '\0';
const char *formatMap = "map %s";
cliDefaultPrintLinef(dumpMask, equalsDefault, formatMap, bufDefault);
if (defaultRxConfig) {
bufDefault[i] = '\0';
cliDefaultPrintLinef(dumpMask, equalsDefault, formatMap, bufDefault);
}
cliDumpPrintLinef(dumpMask, equalsDefault, formatMap, buf);
}