summaryrefslogtreecommitdiffstats
path: root/src/fdr.c
diff options
context:
space:
mode:
authorGravatar BALATON Zoltan2015-05-05 01:16:38 +0200
committerGravatar BALATON Zoltan2015-05-05 01:19:41 +0200
commit9a53b8f2bc3c2ac366d208b620d6404e936e2a92 (patch)
tree821796eeb2fc096ffb886aa8fb9b297421065d37 /src/fdr.c
parente96e7dea1c2cd12ddb2679b7f91775c48aff4d11 (diff)
downloadidevicerestore-9a53b8f2bc3c2ac366d208b620d6404e936e2a92.tar.gz
idevicerestore-9a53b8f2bc3c2ac366d208b620d6404e936e2a92.tar.bz2
Update fdr implementation for thread function changes in latest
libimobiledevice version
Diffstat (limited to 'src/fdr.c')
-rw-r--r--src/fdr.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/fdr.c b/src/fdr.c
index 8d5c9c5..aae92ef 100644
--- a/src/fdr.c
+++ b/src/fdr.c
@@ -21,7 +21,6 @@
#include <sys/types.h>
#include <sys/stat.h>
-#include <errno.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
@@ -33,6 +32,7 @@
#include "common.h"
#include "idevicerestore.h"
#include "fdr.h"
+#include <endianness.h> /* from libimobiledevice */
#define CTRL_PROTO_VERSION 2
#define CTRL_PORT 0x43a /*14852*/
@@ -313,7 +313,7 @@ static int fdr_handle_sync_cmd(fdr_client_t fdr_ctrl)
{
idevice_error_t device_error = IDEVICE_E_SUCCESS;
fdr_client_t fdr;
- thread_t fdr_thread = 0;
+ thread_t fdr_thread = NULL;
int res = 0;
uint32_t bytes = 0;
char buf[4096];
@@ -329,7 +329,7 @@ static int fdr_handle_sync_cmd(fdr_client_t fdr_ctrl)
return -1;
}
debug("FDR connected in reply to sync message, starting command thread\n");
- res = thread_create(&fdr_thread, fdr_listener_thread, fdr);
+ res = thread_new(&fdr_thread, fdr_listener_thread, fdr);
if(res) {
error("ERROR: Failed to start FDR command thread\n");
fdr_free(fdr);