From ae97d58bd5039f7b15cceae7ba2567d5b5728549 Mon Sep 17 00:00:00 2001 From: Ryan Drake Date: Sat, 8 Oct 2016 09:22:17 -0700 Subject: [PATCH] Use zero instead of LIBUSB_ERROR_OTHER as default value for rc --- libx52/x52_control.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libx52/x52_control.c b/libx52/x52_control.c index 6e735b0..e1f4578 100644 --- a/libx52/x52_control.c +++ b/libx52/x52_control.c @@ -22,7 +22,7 @@ int libx52_vendor_command(libx52_device *x52, uint16_t index, uint16_t value) { int j; - int rc = LIBUSB_ERROR_OTHER; + int rc = 0; /* Allow retry in case of failure */ for (j = 0; j < 3; j++) { @@ -168,7 +168,7 @@ int libx52_update(libx52_device *x52) unsigned int i; uint32_t update_mask; uint16_t value; - int rc = LIBUSB_ERROR_OTHER; + int rc = 0; /* Save the update mask */ update_mask = x52->update_mask;