diff options
| author | Admiral H. Curtiss <pikachu025@gmail.com> | 2015-07-01 01:28:41 +0200 |
|---|---|---|
| committer | Jules Blok <jules.blok@gmail.com> | 2015-07-01 23:49:39 +0200 |
| commit | 6a33f174de618dc698ceba02e792cc6b2dba9732 (patch) | |
| tree | 8c478654c01fd1b14434d1ec8b504ba121977019 /Source/Core | |
| parent | 9b95faaed7ca9c50685fe869d59355e771439455 (diff) | |
GC Adapter: Do not attempt to claim_interface when libusb_open() returns an error.
Fixes a crash / nullptr dereference when the adapter is plugged in but
no drivers are installed for it, on Windows.
Diffstat (limited to 'Source/Core')
| -rw-r--r-- | Source/Core/Core/HW/SI_GCAdapter.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Source/Core/Core/HW/SI_GCAdapter.cpp b/Source/Core/Core/HW/SI_GCAdapter.cpp index 7115dc3e40..b54c07ef74 100644 --- a/Source/Core/Core/HW/SI_GCAdapter.cpp +++ b/Source/Core/Core/HW/SI_GCAdapter.cpp @@ -235,6 +235,7 @@ static bool CheckDeviceAccess(libusb_device* device) if (ret == LIBUSB_ERROR_NOT_SUPPORTED) s_libusb_driver_not_supported = true; } + return false; } else if ((ret = libusb_kernel_driver_active(s_handle, 0)) == 1) { |
