summaryrefslogtreecommitdiffstats
path: root/dev/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'dev/main.c')
-rw-r--r--dev/main.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/dev/main.c b/dev/main.c
index 2dbfb4a..f865e52 100644
--- a/dev/main.c
+++ b/dev/main.c
@@ -28,6 +28,7 @@
#include <libxml/tree.h>
#include <libiphone/libiphone.h>
+#include "../src/utils.h"
int main(int argc, char *argv[])
@@ -38,8 +39,10 @@ int main(int argc, char *argv[])
if (argc > 1 && !strcasecmp(argv[1], "--debug")) {
iphone_set_debug(1);
+ iphone_set_debug_mask(DBGMASK_ALL);
} else {
iphone_set_debug(0);
+ iphone_set_debug_mask(DBGMASK_NONE);
}
if (IPHONE_E_SUCCESS != iphone_get_device(&phone)) {
@@ -87,7 +90,7 @@ int main(int argc, char *argv[])
iphone_afc_get_file_attr(afc, "/iTunesOnTheGoPlaylist.plist", &stbuf);
if (IPHONE_E_SUCCESS ==
iphone_afc_open_file(afc, "/iTunesOnTheGoPlaylist.plist", IPHONE_AFC_FILE_READ, &my_file) && my_file) {
- printf("A file size: %i\n", stbuf.st_size);
+ printf("A file size: %i\n", (int) stbuf.st_size);
char *file_data = (char *) malloc(sizeof(char) * stbuf.st_size);
iphone_afc_read_file(afc, my_file, file_data, stbuf.st_size, &bytes);
if (bytes >= 0) {