Reverse the order of operands in an equals comparison to allow the compiler to catch a mistaken use of '=' instead of '=='.

This commit is contained in:
Michael Banther
2019-10-16 14:57:33 +01:00
parent 21ec3cf7bd
commit 024c0304f1

View File

@@ -177,7 +177,7 @@ static XUD_Result_t HidProcessSetIdleRequest( XUD_ep c_ep0_out, XUD_ep c_ep0_in,
Any Interface value other than INTERFACE_NUMBER_HID indicates an error by the USB Host.
*/
if(( 0U == reportId ) && ( interfaceNum == INTERFACE_NUMBER_HID )) {
if(( 0U == reportId ) && ( INTERFACE_NUMBER_HID == interfaceNum )) {
s_hidIdleActive = (( 0U == duration ) || ( ENDPOINT_INT_INTERVAL_IN_HID < duration ));
if( s_hidIdleActive ) {