From: Antonio Ospite Date: Tue, 5 Jan 2016 22:15:00 +0000 (+0100) Subject: kinect_upload_fw: rename "res" to "ret" in main() X-Git-Tag: v0.4~5 X-Git-Url: https://git.ao2.it/kinect-audio-setup.git/commitdiff_plain/67a114d5ae34168db11413b29724891c325484c3?ds=sidebyside;hp=f45467233ef95024e634f008e5d93adf092e842f kinect_upload_fw: rename "res" to "ret" in main() For me it's more a return value than the actual result of some operation. --- diff --git a/kinect_upload_fw/kinect_upload_fw.c b/kinect_upload_fw/kinect_upload_fw.c index d6522ff..1218230 100644 --- a/kinect_upload_fw/kinect_upload_fw.c +++ b/kinect_upload_fw/kinect_upload_fw.c @@ -241,7 +241,7 @@ out: int main(int argc, char** argv) { char default_filename[] = "firmware.bin"; char* filename = default_filename; - int res = 0; + int ret = 0; if (argc == 2) { filename = argv[1]; @@ -259,7 +259,7 @@ int main(int argc, char** argv) { dev = libusb_open_device_with_vid_pid(NULL, KINECT_AUDIO_VID, KINECT_AUDIO_PID); if (dev == NULL) { fprintf(stderr, "Couldn't open device.\n"); - res = -ENODEV; + ret = -ENODEV; goto fail_libusb_open; } @@ -273,11 +273,11 @@ int main(int argc, char** argv) { current_configuration = -1; libusb_get_configuration(dev, ¤t_configuration); if (current_configuration != KINECT_AUDIO_CONFIGURATION) { - res = -ENODEV; + ret = -ENODEV; goto cleanup; } - res = upload_firmware(fw); + ret = upload_firmware(fw); // Now the device reenumerates. cleanup: @@ -286,5 +286,5 @@ cleanup: fail_libusb_open: libusb_exit(NULL); fclose(fw); - return res; + return ret; }