Stefan Reinauer has submitted this change. ( https://review.coreboot.org/c/em100/+/47779 )
Change subject: Fix libusb_claim_interface error handling ......................................................................
Fix libusb_claim_interface error handling
The return value is defined as 0 for success, not greater or equal 0.
Signed-off-by: Stefan Reinauer stefan.reinauer@coreboot.org Change-Id: I8e97258323b45fb2fe13f6fedc7a418165f9ac01 Reviewed-on: https://review.coreboot.org/c/em100/+/47779 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Angel Pons th3fanbus@gmail.com --- M em100.c 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: build bot (Jenkins): Verified Angel Pons: Looks good to me, approved
diff --git a/em100.c b/em100.c index d12e4aa..f7bbb2d 100644 --- a/em100.c +++ b/em100.c @@ -341,7 +341,7 @@ return 0; }
- if (libusb_claim_interface(dev, 0) < 0) { + if (libusb_claim_interface(dev, 0)) { printf("Could not claim interface.\n"); return 0; }