diff options
author | Nikias Bassen | 2019-06-11 01:12:49 +0200 |
---|---|---|
committer | Nikias Bassen | 2019-06-11 01:12:49 +0200 |
commit | 59adbacef6d400d4c6458f26daddda24bcdfd635 (patch) | |
tree | fab41dc53822655f4be988017be4031be64cac33 /src/installation_proxy.c | |
parent | 34444782e22ebfd2abc9e5e9c27e170a839ff66b (diff) | |
download | libimobiledevice-59adbacef6d400d4c6458f26daddda24bcdfd635.tar.gz libimobiledevice-59adbacef6d400d4c6458f26daddda24bcdfd635.tar.bz2 |
common: Update thread.c/.h to match the one from libusbmuxd
Diffstat (limited to 'src/installation_proxy.c')
-rw-r--r-- | src/installation_proxy.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/installation_proxy.c b/src/installation_proxy.c index f82eecc..24044aa 100644 --- a/src/installation_proxy.c +++ b/src/installation_proxy.c @@ -20,6 +20,9 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif #include <string.h> #include <stdlib.h> #include <inttypes.h> @@ -240,7 +243,7 @@ LIBIMOBILEDEVICE_API instproxy_error_t instproxy_client_new(idevice_t device, lo instproxy_client_t client_loc = (instproxy_client_t) malloc(sizeof(struct instproxy_client_private)); client_loc->parent = plistclient; mutex_init(&client_loc->mutex); - client_loc->receive_status_thread = (thread_t)NULL; + client_loc->receive_status_thread = THREAD_T_NULL; *client = client_loc; return INSTPROXY_E_SUCCESS; @@ -264,7 +267,7 @@ LIBIMOBILEDEVICE_API instproxy_error_t instproxy_client_free(instproxy_client_t debug_info("joining receive_status_thread"); thread_join(client->receive_status_thread); thread_free(client->receive_status_thread); - client->receive_status_thread = (thread_t)NULL; + client->receive_status_thread = THREAD_T_NULL; } mutex_destroy(&client->mutex); free(client); @@ -343,7 +346,7 @@ static instproxy_error_t instproxy_receive_status_loop(instproxy_client_t client /* parse status response */ if (node) { - /* check status for possible errorĀ to allow reporting it and aborting it gracefully */ + /* check status for possible error to allow reporting it and aborting it gracefully */ res = instproxy_status_get_error(node, &error_name, &error_description, &error_code); if (res != INSTPROXY_E_SUCCESS) { debug_info("command: %s, error %d, code 0x%08"PRIx64", name: %s, description: \"%s\"", command_name, res, error_code, error_name, error_description ? error_description: "N/A"); @@ -431,7 +434,7 @@ static void* instproxy_receive_status_loop_thread(void* arg) if (data->client->receive_status_thread) { thread_free(data->client->receive_status_thread); - data->client->receive_status_thread = (thread_t)NULL; + data->client->receive_status_thread = THREAD_T_NULL; } instproxy_unlock(data->client); |