From ff62b2d77e0ef8850930c8ce70b4fb3d15621673 Mon Sep 17 00:00:00 2001 From: Demyan Kimitsa Date: Thu, 10 Oct 2019 11:52:53 +0300 Subject: debugserver: Proxy SERVICE_E_TIMEOUT into DEBUGSERVER_E_TIMEOUT This allows proper handling the timeout case in debugserver_client_receive_with_timeout --- include/libimobiledevice/debugserver.h | 1 + src/debugserver.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/include/libimobiledevice/debugserver.h b/include/libimobiledevice/debugserver.h index 8ac116c..8ff31fb 100644 --- a/include/libimobiledevice/debugserver.h +++ b/include/libimobiledevice/debugserver.h @@ -39,6 +39,7 @@ typedef enum { DEBUGSERVER_E_MUX_ERROR = -2, DEBUGSERVER_E_SSL_ERROR = -3, DEBUGSERVER_E_RESPONSE_ERROR = -4, + DEBUGSERVER_E_TIMEOUT = -5, DEBUGSERVER_E_UNKNOWN_ERROR = -256 } debugserver_error_t; diff --git a/src/debugserver.c b/src/debugserver.c index 447a91e..4aab1fc 100644 --- a/src/debugserver.c +++ b/src/debugserver.c @@ -55,6 +55,8 @@ static debugserver_error_t debugserver_error(service_error_t err) return DEBUGSERVER_E_MUX_ERROR; case SERVICE_E_SSL_ERROR: return DEBUGSERVER_E_SSL_ERROR; + case SERVICE_E_TIMEOUT: + return DEBUGSERVER_E_TIMEOUT; default: break; } -- cgit v1.1-32-gdbae