darwin: clean up some code. remove a clang warning

The check for NULL != cached_device was unnecessary and caused clang's
static analysis to print out a warning.
darwin: return libusb error codes instead of kernel error codes and fix
a bug introduced in the last commit.
Release 1.0.17-rc1

Signed-off-by: Hans de Goede <hdegoede@redhat.com>