summaryrefslogtreecommitdiffstats
path: root/src/asr.c
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2010-07-09 23:38:53 +0200
committerGravatar Martin Szulecki2010-07-09 23:38:53 +0200
commit9433af8a8c8f6d8718712d59547d3c333402551b (patch)
treea18af2474b8b49c39457a8081cdbe9773a0e623c /src/asr.c
parent853e499d97d2dd0c2b9dcc0ff3398f0295832132 (diff)
downloadidevicerestore-9433af8a8c8f6d8718712d59547d3c333402551b.tar.gz
idevicerestore-9433af8a8c8f6d8718712d59547d3c333402551b.tar.bz2
Only debug a plist if debugging flag was set
Diffstat (limited to 'src/asr.c')
-rw-r--r--src/asr.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/asr.c b/src/asr.c
index 3f9b392..f48170a 100644
--- a/src/asr.c
+++ b/src/asr.c
@@ -87,7 +87,9 @@ int asr_receive(idevice_connection_t asr, plist_t* data) {
*data = request;
- debug("Received %d bytes:\n%s\n", size, buffer);
+ debug("Received %d bytes:\n", size);
+ if (idevicerestore_debug)
+ debug_plist(request);
free(buffer);
return 0;
}
@@ -104,7 +106,8 @@ int asr_send(idevice_connection_t asr, plist_t* data) {
}
debug("Sent %d bytes:\n", size);
- debug_plist(data);
+ if (idevicerestore_debug)
+ debug_plist(*data);
free(buffer);
return 0;
}
@@ -119,6 +122,8 @@ int asr_send_buffer(idevice_connection_t asr, const char* data, uint32_t size) {
return -1;
}
+ debug("Sent %d bytes buffer\n", bytes);
+
return 0;
}