aboutsummaryrefslogtreecommitdiff
path: root/Demos/Device/Incomplete/Sideshow/Sideshow.c
diff options
context:
space:
mode:
authorDean Camera <[email protected]>2010-07-21 16:19:32 +0000
committerDean Camera <[email protected]>2010-07-21 16:19:32 +0000
commit6bda628718f67c04ed43e8328f55bdce5319c504 (patch)
treeefd08eefa90cef94440f880a70902f5803fb12a7 /Demos/Device/Incomplete/Sideshow/Sideshow.c
parent83e293a6ec98c7faad1b76dd312b31b86cbeecc1 (diff)
downloadqmk_firmware-6bda628718f67c04ed43e8328f55bdce5319c504.tar.gz
qmk_firmware-6bda628718f67c04ed43e8328f55bdce5319c504.zip
Update all demos, projects and bootloaders to indent all function parameters, one per line, for better readability.
Add missing const qualifiers to the demos.
Diffstat (limited to 'Demos/Device/Incomplete/Sideshow/Sideshow.c')
-rw-r--r--Demos/Device/Incomplete/Sideshow/Sideshow.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/Demos/Device/Incomplete/Sideshow/Sideshow.c b/Demos/Device/Incomplete/Sideshow/Sideshow.c
index 3e9778e29a..2972e0cf72 100644
--- a/Demos/Device/Incomplete/Sideshow/Sideshow.c
+++ b/Demos/Device/Incomplete/Sideshow/Sideshow.c
@@ -122,13 +122,11 @@ void EVENT_USB_Device_UnhandledControlRequest(void)
if (USB_ControlRequest.bmRequestType == (REQDIR_DEVICETOHOST | REQTYPE_VENDOR | REQREC_DEVICE))
{
void* DescriptorPointer;
- uint16_t DescriptorSize;
+ uint16_t DescriptorSize = USB_GetOSFeatureDescriptor(USB_ControlRequest.wValue, USB_ControlRequest.wIndex,
+ &DescriptorPointer, &DescriptorSize);
- if (!(USB_GetOSFeatureDescriptor(USB_ControlRequest.wValue, USB_ControlRequest.wIndex,
- &DescriptorPointer, &DescriptorSize)))
- {
- return;
- }
+ if (DescriptorSize == NO_DESCRIPTOR)
+ return;
Endpoint_ClearSETUP();