Fix checking of return value of GetBuffer() in AudioEndpointRequests_1()

This commit is contained in:
Ross Owen
2022-04-26 13:26:41 +01:00
committed by GitHub
parent edd34ac157
commit 392e00f989

View File

@@ -1095,7 +1095,7 @@ int AudioEndpointRequests_1(XUD_ep ep0_out, XUD_ep ep0_in, USB_SetupPacket_t &sp
/* Check Control Selector */
unsigned short controlSelector = sp.wValue>>8;
if((result != XUD_GetBuffer(ep0_out, (buffer, unsigned char[]), length)) != XUD_RES_OKAY)
if((result = XUD_GetBuffer(ep0_out, (buffer, unsigned char[]), length)) != XUD_RES_OKAY)
{
return result;
}