Linux: Fix warnings seen when compiling with gcc-4.6
authorHans de Goede <hdegoede@redhat.com>
Wed, 9 Feb 2011 11:40:35 +0000 (12:40 +0100)
committerPeter Stuge <peter@stuge.se>
Sun, 24 Jul 2011 21:33:59 +0000 (23:33 +0200)
commita68f956dd4c29d6ed799f04f07a3346317843999
tree65940cad256e15f59a050a5dde0e4317b0ac875e
parent209b5ccd827039b933b730e3f29abd0d72d3c6c6
Linux: Fix warnings seen when compiling with gcc-4.6

Compiling with gcc-4.6 results in the following warnings:
os/linux_usbfs.c: In function 'op_get_configuration':
os/linux_usbfs.c:1144:6: warning: variable 'r' set but not used ...
os/linux_usbfs.c: In function 'op_handle_events':
os/linux_usbfs.c:2091:40: warning: 'status' may be used uninitialized ...
os/linux_usbfs.c:2044:6: note: 'status' was declared here
dpfp.c: In function 'save_to_file':
dpfp.c:228:9: warning: variable 'ignore' set but not used ...
dpfp_threaded.c: In function 'save_to_file':
dpfp_threaded.c:257:9: warning: variable 'ignore' set but not used ...

This patch fixes these. (The second comes from handle_control_completion()
which gcc seems to inline into op_handle_events().)

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
[stuge: Add fixes for dpfp examples and update source references]
examples/dpfp.c
examples/dpfp_threaded.c
libusb/os/linux_usbfs.c