Quick and dirty: use a memory address actually usable with DMA

This commit is contained in:
Raphael Coeffic
2021-11-21 11:18:35 +01:00
committed by Raphael Coeffic
parent c95667394c
commit 4124d0a950
+4 -1
View File
@@ -903,7 +903,7 @@ int cliSerialPassthrough(const char **argv)
if (port_n == INTERNAL_MODULE) {
// TODO: check the stack level so we don't crash it
uint8_t tmpBuf[256];
uint8_t* tmpBuf = (uint8_t*)malloc(256);
// setup serial com
// TODO:
@@ -931,6 +931,9 @@ int cliSerialPassthrough(const char **argv)
serialPutc(inData);
}
}
free(tmpBuf);
tmpBuf = nullptr;
}
#endif