diff options
Diffstat (limited to 'src/cleanindex.c')
-rw-r--r-- | src/cleanindex.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/cleanindex.c b/src/cleanindex.c deleted file mode 100644 index fb15bed..0000000 --- a/src/cleanindex.c +++ /dev/null | |||
@@ -1,23 +0,0 @@ | |||
1 | #include "mystdlib.h" | ||
2 | #include <sys/mman.h> | ||
3 | #include <fcntl.h> | ||
4 | |||
5 | static int indexed = -1; | ||
6 | |||
7 | int main( int argc, char **argv ) { | ||
8 | MAP index = NULL; | ||
9 | int i; | ||
10 | |||
11 | if( argc != 2 ) | ||
12 | { fputs( "Syntax: cleanindex <indexfile>", stderr); exit( 1 ); } | ||
13 | |||
14 | if( !(index = map_file( argv[1], 0 ) ) ) exit( 1 ); | ||
15 | |||
16 | for( i = 0; i < index->size; i+= 16 ) | ||
17 | *((unsigned long*)(index->addr + i)) += *((unsigned char*)index->addr + i + 4); | ||
18 | |||
19 | unmap_file( &index ); | ||
20 | close( indexed ); | ||
21 | |||
22 | return 0; | ||
23 | } | ||