Skip to content

Commit 5f849ab

Browse files
committed
Fixed some warnings
1 parent 1a4e885 commit 5f849ab

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

cores/arduino/SERCOM.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -633,7 +633,7 @@ void SERCOM::initClockNVIC( void )
633633
clockId = GCM_SERCOM4_CORE;
634634
IdNvic = SERCOM4_IRQn;
635635
}
636-
else if(sercom == SERCOM5)
636+
else // if(sercom == SERCOM5)
637637
{
638638
clockId = GCM_SERCOM5_CORE;
639639
IdNvic = SERCOM5_IRQn;

cores/arduino/USB/USBCore.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ uint32_t USBD_Available(uint32_t ep)
105105
// Return number of bytes read
106106
uint32_t USBD_Recv(uint32_t ep, void* d, uint32_t len)
107107
{
108-
if (!_usbConfiguration || len < 0)
108+
if (!_usbConfiguration)
109109
return -1;
110110

111111
uint32_t n = UDD_FifoByteCount(ep);
@@ -200,8 +200,8 @@ uint32_t USBD_RecvControl(void* d, uint32_t len)
200200
if (read > len)
201201
read = len;
202202
UDD_Recv(EP0, &buffer);
203-
while (!udd_is_OUT_transf_cplt(EP0));
204-
for (int i=0; i<read; i++) {
203+
while (!udd_is_OUT_transf_cplt(EP0));
204+
for (uint32_t i=0; i<read; i++) {
205205
data[i] = buffer[i];
206206
}
207207
udd_OUT_transfer_allowed(EP0);

0 commit comments

Comments
 (0)