Skip to content

Commit

Permalink
Make it compile again when building --with-dummy
Browse files Browse the repository at this point in the history
  • Loading branch information
nikias committed Dec 30, 2023
1 parent 0a0ad0c commit 2fff426
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions src/libirecovery.c
Original file line number Diff line number Diff line change
Expand Up @@ -1615,15 +1615,11 @@ static irecv_error_t iokit_open_with_ecid(irecv_client_t* pclient, uint64_t ecid
return iokit_usb_open_service(pclient, ret_service);
}
#endif
#endif

#ifndef WIN32
#ifndef HAVE_IOKIT
static irecv_error_t libusb_usb_open_handle_with_descriptor_and_ecid(irecv_client_t *pclient, struct libusb_device_handle *usb_handle, struct libusb_device_descriptor *usb_descriptor, uint64_t ecid)
{
irecv_error_t ret = IRECV_E_UNABLE_TO_CONNECT;
irecv_error_t error = IRECV_E_UNABLE_TO_CONNECT;

irecv_client_t client = (irecv_client_t) malloc(sizeof(struct irecv_client_private));
if (client == NULL) {
libusb_close(usb_handle);
Expand All @@ -1650,9 +1646,8 @@ static irecv_error_t libusb_usb_open_handle_with_descriptor_and_ecid(irecv_clien
debug("found device with ECID %016" PRIx64 "\n", (uint64_t)ecid);
}

ret = IRECV_E_SUCCESS;
*pclient = client;
return ret;
return IRECV_E_SUCCESS;
}

static irecv_error_t libusb_open_with_ecid(irecv_client_t* pclient, uint64_t ecid)
Expand Down Expand Up @@ -1719,6 +1714,7 @@ static irecv_error_t libusb_open_with_ecid(irecv_client_t* pclient, uint64_t eci
}
#endif
#endif
#endif

irecv_error_t irecv_open_with_ecid(irecv_client_t* pclient, uint64_t ecid)
{
Expand Down Expand Up @@ -3062,7 +3058,6 @@ static irecv_error_t irecv_get_status(irecv_client_t client, unsigned int* statu

return IRECV_E_SUCCESS;
}
#endif

static irecv_error_t irecv_kis_send_buffer(irecv_client_t client, unsigned char* buffer, unsigned long length, int dfu_notify_finished)
{
Expand Down Expand Up @@ -3126,6 +3121,7 @@ static irecv_error_t irecv_kis_send_buffer(irecv_client_t client, unsigned char*

return IRECV_E_SUCCESS;
}
#endif

irecv_error_t irecv_send_buffer(irecv_client_t client, unsigned char* buffer, unsigned long length, int dfu_notify_finished)
{
Expand Down

0 comments on commit 2fff426

Please sign in to comment.