diff options
-rw-r--r-- | rbutil/ipodpatcher/main.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/rbutil/ipodpatcher/main.c b/rbutil/ipodpatcher/main.c index 476aeff9d2..e60b1d7034 100644 --- a/rbutil/ipodpatcher/main.c +++ b/rbutil/ipodpatcher/main.c | |||
@@ -29,7 +29,7 @@ | |||
29 | #include "ipodpatcher.h" | 29 | #include "ipodpatcher.h" |
30 | #include "ipodio.h" | 30 | #include "ipodio.h" |
31 | 31 | ||
32 | #define VERSION "0.8 with r12194-070204 bootloaders" | 32 | #define VERSION "0.9 with v1.0 bootloaders" |
33 | 33 | ||
34 | int verbose = 0; | 34 | int verbose = 0; |
35 | 35 | ||
@@ -326,9 +326,10 @@ int main(int argc, char* argv[]) | |||
326 | #ifdef WITH_BOOTOBJS | 326 | #ifdef WITH_BOOTOBJS |
327 | } else if (action==INTERACTIVE) { | 327 | } else if (action==INTERACTIVE) { |
328 | 328 | ||
329 | printf("Do you wish to install the rockbox bootloader? (y/n) :"); | 329 | printf("Enter i to install the Rockbox bootloader, u to uninstall\n or c to cancel and do nothing (i/u/c) :"); |
330 | |||
330 | if (fgets(yesno,4,stdin)) { | 331 | if (fgets(yesno,4,stdin)) { |
331 | if (yesno[0]=='y') { | 332 | if (yesno[0]=='i') { |
332 | if (ipod_reopen_rw(&ipod) < 0) { | 333 | if (ipod_reopen_rw(&ipod) < 0) { |
333 | return 5; | 334 | return 5; |
334 | } | 335 | } |
@@ -338,6 +339,16 @@ int main(int argc, char* argv[]) | |||
338 | } else { | 339 | } else { |
339 | fprintf(stderr,"[ERR] --install failed.\n"); | 340 | fprintf(stderr,"[ERR] --install failed.\n"); |
340 | } | 341 | } |
342 | } else if (yesno[0]=='u') { | ||
343 | if (ipod_reopen_rw(&ipod) < 0) { | ||
344 | return 5; | ||
345 | } | ||
346 | |||
347 | if (delete_bootloader(&ipod)==0) { | ||
348 | fprintf(stderr,"[INFO] Bootloader removed.\n"); | ||
349 | } else { | ||
350 | fprintf(stderr,"[ERR] Bootloader removal failed.\n"); | ||
351 | } | ||
341 | } | 352 | } |
342 | } | 353 | } |
343 | #endif | 354 | #endif |