From 75422de6d18a126af5fe52fc66457f676f0e16f6 Mon Sep 17 00:00:00 2001 From: Michael Banther Date: Wed, 25 Sep 2019 11:42:59 +0100 Subject: [PATCH] Replace existing #ifdef HID_CONTROLS with #if( 0 < HID_CONTROLS ) to move to best practice regarding compile-time switches. --- lib_xua/src/core/endpoint0/xua_ep0_descriptors.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib_xua/src/core/endpoint0/xua_ep0_descriptors.h b/lib_xua/src/core/endpoint0/xua_ep0_descriptors.h index ea34ac2b..0f762d61 100644 --- a/lib_xua/src/core/endpoint0/xua_ep0_descriptors.h +++ b/lib_xua/src/core/endpoint0/xua_ep0_descriptors.h @@ -547,7 +547,7 @@ unsigned char devQualDesc_Null[] = #endif -#ifdef HID_CONTROLS +#if( 0 < HID_CONTROLS ) unsigned char hidReportDescriptor[] = { 0x05, 0x0c, /* Usage Page (Consumer Device) */ @@ -769,7 +769,7 @@ typedef struct #endif #endif -#ifdef HID_CONTROLS +#if( 0 < HID_CONTROLS ) USB_Descriptor_Interface_t HID_Interface; unsigned char hidDesc[9]; //TODO ideally we would have a struct for this. USB_Descriptor_Endpoint_t HID_In_Endpoint; @@ -2153,7 +2153,7 @@ USB_Config_Descriptor_Audio2_t cfgDesc_Audio2= #endif #endif /* IAP */ -#ifdef HID_CONTROLS +#if( 0 < HID_CONTROLS ) .HID_Interface = { 9, /* 0 bLength : Size of descriptor in Bytes */ @@ -2194,7 +2194,7 @@ USB_Config_Descriptor_Audio2_t cfgDesc_Audio2= }; #endif /* (AUDIO_CLASS == 2) */ -#ifdef HID_CONTROLS +#if( 0 < HID_CONTROLS ) unsigned char hidDescriptor[] = { 9, /* 0 bLength : Size of descriptor in Bytes */