summaryrefslogtreecommitdiffstats
path: root/libirecovery.c
diff options
context:
space:
mode:
authorGravatar Nikias Bassen2012-07-04 21:22:31 +0200
committerGravatar Nikias Bassen2012-07-04 21:22:31 +0200
commit99e00a1610bc71df7393fa3e3da44995f3c48b12 (patch)
tree4ddeb444bfa75b08b6cae167ae6f3a17b9121d83 /libirecovery.c
parent91685ab35d781877724e78da5a3c505478906ce5 (diff)
downloadlibirecovery-99e00a1610bc71df7393fa3e3da44995f3c48b12.tar.gz
libirecovery-99e00a1610bc71df7393fa3e3da44995f3c48b12.tar.bz2
win32: correctly enable debug mode
Diffstat (limited to 'libirecovery.c')
-rw-r--r--libirecovery.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/libirecovery.c b/libirecovery.c
index b83a8d2..c061b2f 100644
--- a/libirecovery.c
+++ b/libirecovery.c
@@ -505,6 +505,9 @@ int irecv_get_string_descriptor_ascii(irecv_client_t client, uint8_t desc_index,
}
irecv_error_t irecv_open(irecv_client_t* pclient, unsigned long long ecid) {
+ if(libirecovery_debug) {
+ irecv_set_debug_level(libirecovery_debug);
+ }
#ifndef WIN32
int i = 0;
struct libusb_device* usb_device = NULL;
@@ -513,10 +516,6 @@ irecv_error_t irecv_open(irecv_client_t* pclient, unsigned long long ecid) {
struct libusb_device_descriptor usb_descriptor;
*pclient = NULL;
- if(libirecovery_debug) {
- irecv_set_debug_level(libirecovery_debug);
- }
-
irecv_error_t error = IRECV_E_SUCCESS;
int usb_device_count = libusb_get_device_list(libirecovery_context, &usb_device_list);
for (i = 0; i < usb_device_count; i++) {