summaryrefslogtreecommitdiffstats
path: root/src/mobilebackup2.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mobilebackup2.c')
-rw-r--r--src/mobilebackup2.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mobilebackup2.c b/src/mobilebackup2.c
index bcf5944..15ba469 100644
--- a/src/mobilebackup2.c
+++ b/src/mobilebackup2.c
@@ -279,13 +279,13 @@ mobilebackup2_error_t mobilebackup2_send_raw(mobilebackup2_client_t client, cons
279 279
280 *bytes = 0; 280 *bytes = 0;
281 281
282 idevice_connection_t conn = client->parent->parent->connection; 282 service_client_t raw = client->parent->parent->parent;
283 283
284 int bytes_loc = 0; 284 int bytes_loc = 0;
285 uint32_t sent = 0; 285 uint32_t sent = 0;
286 do { 286 do {
287 bytes_loc = 0; 287 bytes_loc = 0;
288 idevice_connection_send(conn, data+sent, length-sent, (uint32_t*)&bytes_loc); 288 service_send(raw, data+sent, length-sent, (uint32_t*)&bytes_loc);
289 if (bytes_loc <= 0) 289 if (bytes_loc <= 0)
290 break; 290 break;
291 sent += bytes_loc; 291 sent += bytes_loc;
@@ -321,7 +321,7 @@ mobilebackup2_error_t mobilebackup2_receive_raw(mobilebackup2_client_t client, c
321 if (!client || !client->parent || !data || (length == 0) || !bytes) 321 if (!client || !client->parent || !data || (length == 0) || !bytes)
322 return MOBILEBACKUP2_E_INVALID_ARG; 322 return MOBILEBACKUP2_E_INVALID_ARG;
323 323
324 idevice_connection_t conn = client->parent->parent->connection; 324 service_client_t raw = client->parent->parent->parent;
325 325
326 *bytes = 0; 326 *bytes = 0;
327 327
@@ -329,7 +329,7 @@ mobilebackup2_error_t mobilebackup2_receive_raw(mobilebackup2_client_t client, c
329 uint32_t received = 0; 329 uint32_t received = 0;
330 do { 330 do {
331 bytes_loc = 0; 331 bytes_loc = 0;
332 idevice_connection_receive(conn, data+received, length-received, (uint32_t*)&bytes_loc); 332 service_receive(raw, data+received, length-received, (uint32_t*)&bytes_loc);
333 if (bytes_loc <= 0) break; 333 if (bytes_loc <= 0) break;
334 received += bytes_loc; 334 received += bytes_loc;
335 } while (received < length); 335 } while (received < length);