summaryrefslogtreecommitdiffstats
path: root/src/utils.c
diff options
context:
space:
mode:
authorGravatar Matt Colyer2009-07-26 19:34:22 -0700
committerGravatar Matt Colyer2009-07-26 19:34:22 -0700
commiteea538c94f01f8054f69f059614f19400187a472 (patch)
tree209a12dc8c8eaece15b8153d15e689c8c2147ab6 /src/utils.c
parent8ebfd7d8eea89bb27e4e6dbb1f37fd90d98b439c (diff)
parent19c9750d670435ce430f0fc85a55faf127bdfbf9 (diff)
downloadlibimobiledevice-eea538c94f01f8054f69f059614f19400187a472.tar.gz
libimobiledevice-eea538c94f01f8054f69f059614f19400187a472.tar.bz2
Merge commit 'martin-s/martin'
[#46 state:resolved]
Diffstat (limited to 'src/utils.c')
-rw-r--r--src/utils.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/utils.c b/src/utils.c
index 5b0872d..3c08351 100644
--- a/src/utils.c
+++ b/src/utils.c
@@ -20,7 +20,10 @@
*/
#include <stdarg.h>
#include <stdio.h>
+#include <stdint.h>
+
#include "utils.h"
+#include "libiphone/libiphone.h"
int toto_debug = 0;
uint16_t dbg_mask = 0;
@@ -31,7 +34,7 @@ uint16_t dbg_mask = 0;
*
* @param level Set to 0 for no debugging or 1 for debugging.
*/
-void iphone_set_debug(int level)
+void iphone_set_debug_level(int level)
{
toto_debug = level;
}
@@ -116,13 +119,12 @@ inline void log_debug_buffer(const char *data, const int length)
inline void dump_debug_buffer(const char *file, const char *data, const int length)
{
#ifndef STRIP_DEBUG_CODE
-
/* run the real fprintf */
if (toto_debug) {
FILE *my_ssl_packet = fopen(file, "w+");
fwrite(data, 1, length, my_ssl_packet);
fflush(my_ssl_packet);
- fprintf(stderr, "Wrote SSL packet to drive, too.\n");
+ fprintf(stderr, "%s: Wrote SSL packet to drive, too.\n", __func__);
fclose(my_ssl_packet);
}
#endif