diff options
author | Marti Bolivar <mbolivar@leaflabs.com> | 2011-02-09 17:55:45 -0500 |
---|---|---|
committer | Marti Bolivar <mbolivar@leaflabs.com> | 2011-02-09 17:55:45 -0500 |
commit | 7366564129bf4e4030e9083f4521eda49d985fb8 (patch) | |
tree | 403914a8e3fa609e4c19d97ba61cb585e7391d97 | |
parent | 90adb6bff63e3ecad81d300651a40d8835efc608 (diff) | |
download | librambutan-7366564129bf4e4030e9083f4521eda49d985fb8.tar.gz librambutan-7366564129bf4e4030e9083f4521eda49d985fb8.zip |
Fixing usb.c countTx race; thanks, geoffreymbrown!
-rw-r--r-- | libmaple/usb/usb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libmaple/usb/usb.c b/libmaple/usb/usb.c index 923e54b..39bf31a 100644 --- a/libmaple/usb/usb.c +++ b/libmaple/usb/usb.c @@ -376,8 +376,8 @@ uint16 usbSendBytes(uint8* sendBuf, uint16 len) { if (loaded) { UserToPMABufferCopy(sendBuf,VCOM_TX_ADDR + countTx, loaded); _SetEPTxCount(VCOM_TX_ENDP, countTx+loaded); - _SetEPTxValid(VCOM_TX_ENDP); countTx += loaded; + _SetEPTxValid(VCOM_TX_ENDP); } return loaded; |