aboutsummaryrefslogtreecommitdiff
path: root/cores/arduino/USBCore.cpp
diff options
context:
space:
mode:
authorDavid Madison <dmadison@users.noreply.github.com>2019-02-17 12:07:22 -0500
committerDavid Madison <dmadison@users.noreply.github.com>2019-02-17 12:07:22 -0500
commit9e9f54d34dbab45e152d8163e048a879d736eedf (patch)
tree7b927797fe5d478e27e49381d1aa94ed5f019992 /cores/arduino/USBCore.cpp
parent5755ddea49fa69d6c505c772ebee5af5078e2ebf (diff)
Define descriptor return var in pluggable block
Avoids unused variable warning if USB is enabled but pluggable USB is not
Diffstat (limited to 'cores/arduino/USBCore.cpp')
-rw-r--r--cores/arduino/USBCore.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/cores/arduino/USBCore.cpp b/cores/arduino/USBCore.cpp
index c0a4c7c..dc6bc38 100644
--- a/cores/arduino/USBCore.cpp
+++ b/cores/arduino/USBCore.cpp
@@ -496,14 +496,13 @@ bool SendConfiguration(int maxlen)
static
bool SendDescriptor(USBSetup& setup)
{
- int ret;
u8 t = setup.wValueH;
if (USB_CONFIGURATION_DESCRIPTOR_TYPE == t)
return SendConfiguration(setup.wLength);
InitControl(setup.wLength);
#ifdef PLUGGABLE_USB_ENABLED
- ret = PluggableUSB().getDescriptor(setup);
+ int ret = PluggableUSB().getDescriptor(setup);
if (ret != 0) {
return (ret > 0 ? true : false);
}