summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/extractblocks_new.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/extractblocks_new.c b/src/extractblocks_new.c
index 580d3ad..fe85252 100644
--- a/src/extractblocks_new.c
+++ b/src/extractblocks_new.c
@@ -29,7 +29,7 @@ static uint8_t mantra_in[] = { 0x68, 0x35, 0x2d, 0x6c };
29int main( int args, char **argv ) 29int main( int args, char **argv )
30{ 30{
31 int filenum = 0, run = 1; 31 int filenum = 0, run = 1;
32 size_t offset = 0, oldoffset = -1, enc_len = 32; 32 size_t offset = 0, oldoffset = -1, reported = 0, enc_len = 32;
33 uint8_t mantra[4], id0, id5, *mappedfile; 33 uint8_t mantra[4], id0, id5, *mappedfile;
34 MAP map; 34 MAP map;
35 35
@@ -72,7 +72,14 @@ int main( int args, char **argv )
72 ( mappedfile[ offset + 6 ] != ( '-' ^ mantra[2] )) 72 ( mappedfile[ offset + 6 ] != ( '-' ^ mantra[2] ))
73 ) ) offset++; 73 ) ) offset++;
74 74
75 printf( "Found an appropriate offset at: %zd\n", offset ); 75 // printf( "Found an appropriate offset at: %zd\n", offset );
76
77 if( reported < ( offset * 10 ) / map->size )
78 {
79 reported++;
80 printf( "%zd%% ", 10 * reported );
81 fflush( stdout );
82 }
76 83
77 if( offset == map->size ) 84 if( offset == map->size )
78 run = 0; 85 run = 0;