fork
Dependencies: BLE_API mbed-dev-bin nRF51822
Fork of microbit-dal by
Diff: source/bluetooth/MicroBitUARTService.cpp
- Revision:
- 8:ec4465853952
- Parent:
- 3:d86a4ddc1867
- Child:
- 29:62f8b007debf
--- a/source/bluetooth/MicroBitUARTService.cpp Thu Apr 07 23:39:33 2016 +0100 +++ b/source/bluetooth/MicroBitUARTService.cpp Thu Apr 07 23:39:34 2016 +0100 @@ -256,6 +256,8 @@ uint8_t temp[size]; + memclr(&temp, size); + circularCopy(txBuffer, txBufferSize, temp, txBufferTail, txBufferHead); #if CONFIG_ENABLED(MICROBIT_DBG) @@ -361,6 +363,8 @@ { uint8_t buf[len + 1]; + memclr(&buf, len + 1); + int ret = read(buf, len, mode); if(ret < 1) @@ -428,6 +432,8 @@ uint8_t localBuff[localBuffSize + 1]; + memclr(&localBuff, localBuffSize + 1); + circularCopy(rxBuffer, rxBufferSize, localBuff, preservedTail, foundIndex); //plus one for the character we listened for...