summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSean McBride <sean@rogue-research.com>2014-04-22 16:52:29 -0400
committerNathan Hjelm <hjelmn@me.com>2014-05-06 01:28:08 -0600
commita8f1784c00e62576b0ba1bcf4de86517e2ebd6ef (patch)
treed9a1cd3a98d3544a3407325288f99fad573458a9
parent6d8dfe0aee41a3c7dd862c3de488df3ce452d86e (diff)
downloadlibusb-a8f1784c00e62576b0ba1bcf4de86517e2ebd6ef.tar.gz
Removed unneeded casts
The parameters already match the function declaration; no need to cast.
-rw-r--r--libusb/os/darwin_usb.c10
-rw-r--r--libusb/version_nano.h2
2 files changed, 6 insertions, 6 deletions
diff --git a/libusb/os/darwin_usb.c b/libusb/os/darwin_usb.c
index 5963965..b66fe80 100644
--- a/libusb/os/darwin_usb.c
+++ b/libusb/os/darwin_usb.c
@@ -346,8 +346,8 @@ static void *darwin_event_thread_main (void *arg0) {
/* create notifications for removed devices */
kresult = IOServiceAddMatchingNotification (libusb_notification_port, kIOTerminatedNotification,
IOServiceMatching(kIOUSBDeviceClassName),
- (IOServiceMatchingCallback)darwin_devices_detached,
- (void *)ctx, &libusb_rem_device_iterator);
+ darwin_devices_detached,
+ ctx, &libusb_rem_device_iterator);
if (kresult != kIOReturnSuccess) {
usbi_err (ctx, "could not add hotplug event source: %s", darwin_error_str (kresult));
@@ -358,8 +358,8 @@ static void *darwin_event_thread_main (void *arg0) {
/* create notifications for attached devices */
kresult = IOServiceAddMatchingNotification(libusb_notification_port, kIOFirstMatchNotification,
IOServiceMatching(kIOUSBDeviceClassName),
- (IOServiceMatchingCallback)darwin_devices_attached,
- (void *)ctx, &libusb_add_device_iterator);
+ darwin_devices_attached,
+ ctx, &libusb_add_device_iterator);
if (kresult != kIOReturnSuccess) {
usbi_err (ctx, "could not add hotplug event source: %s", darwin_error_str (kresult));
@@ -429,7 +429,7 @@ static int darwin_init(struct libusb_context *ctx) {
host_get_clock_service(host_self, SYSTEM_CLOCK, &clock_monotonic);
mach_port_deallocate(mach_task_self(), host_self);
- pthread_create (&libusb_darwin_at, NULL, darwin_event_thread_main, (void *)ctx);
+ pthread_create (&libusb_darwin_at, NULL, darwin_event_thread_main, ctx);
pthread_mutex_lock (&libusb_darwin_at_mutex);
while (!libusb_darwin_acfl)
diff --git a/libusb/version_nano.h b/libusb/version_nano.h
index 3f71231..82c1717 100644
--- a/libusb/version_nano.h
+++ b/libusb/version_nano.h
@@ -1 +1 @@
-#define LIBUSB_NANO 10880
+#define LIBUSB_NANO 10881