diff options
author | Martin Szulecki | 2013-09-26 09:47:18 +0200 |
---|---|---|
committer | Martin Szulecki | 2013-09-26 09:47:18 +0200 |
commit | 0cdd324d729a6864a95b7343c6927a7819047141 (patch) | |
tree | db87f4a8ee35ee2d21b9d63a92c3f4faf60e7137 | |
parent | 9099c5d9e28ca6348fc1b0431f47e2592649ae84 (diff) | |
download | libirecovery-0cdd324d729a6864a95b7343c6927a7819047141.tar.gz libirecovery-0cdd324d729a6864a95b7343c6927a7819047141.tar.bz2 |
Remove rather obsolete irecv_hexdump() helper
-rw-r--r-- | include/libirecovery.h | 2 | ||||
-rw-r--r-- | src/libirecovery.c | 36 |
2 files changed, 0 insertions, 38 deletions
diff --git a/include/libirecovery.h b/include/libirecovery.h index 05ff13f..56e5fd2 100644 --- a/include/libirecovery.h +++ b/include/libirecovery.h @@ -229,8 +229,6 @@ irecv_error_t irecv_get_nonce(irecv_client_t client, unsigned char** nonce, int* irecv_error_t irecv_get_srnm(irecv_client_t client, char* srnm); irecv_error_t irecv_get_imei(irecv_client_t client, char* imei); -void irecv_hexdump(unsigned char* buf, unsigned int len, unsigned int addr); - void irecv_init(); void irecv_exit(); irecv_client_t irecv_reconnect(irecv_client_t client, int initial_pause); diff --git a/src/libirecovery.c b/src/libirecovery.c index c7186a0..e82bce2 100644 --- a/src/libirecovery.c +++ b/src/libirecovery.c @@ -1549,39 +1549,3 @@ irecv_client_t irecv_reconnect(irecv_client_t client, int initial_pause) { new_client->progress_callback = progress_callback; return new_client; } - -void irecv_hexdump(unsigned char* buf, unsigned int len, unsigned int addr) { - int i, j; - printf("0x%08x: ", addr); - for (i = 0; i < (int)len; i++) { - if (i % 16 == 0 && i != 0) { - for (j=i-16; j < i; j++) { - unsigned char car = buf[j]; - if (car < 0x20 || car > 0x7f) car = '.'; - printf("%c", car); - } - printf("\n"); - addr += 0x10; - printf("0x%08x: ", addr); - } - printf("%02x ", buf[i]); - } - - int done = (i % 16); - int remains = 16 - done; - if (done > 0) { - for (j = 0; j < remains; j++) { - printf(" "); - } - } - - if ((i - done) >= 0) { - if (done == 0 && i > 0) done = 16; - for (j = (i - done); j < i; j++) { - unsigned char car = buf[j]; - if (car < 0x20 || car > 0x7f) car = '.'; - printf("%c", car); - } - } - printf("\n"); -} |