Whamcloud - gitweb
libext2fs: remove useless test and assignment in strtohashbuf()
[tools/e2fsprogs.git] / lib / ext2fs / tst_iscan.c
index 6c3abb3..70bfbec 100644 (file)
@@ -4,11 +4,12 @@
  * Copyright (C) 1996 by Theodore Ts'o.
  *
  * %Begin-Header%
- * This file may be redistributed under the terms of the GNU Public
- * License.
+ * This file may be redistributed under the terms of the GNU Library
+ * General Public License, version 2.
  * %End-Header%
  */
 
+#include "config.h"
 #include <stdio.h>
 #include <string.h>
 #if HAVE_UNISTD_H
@@ -25,7 +26,7 @@
 #include "ext2_fs.h"
 #include "ext2fs.h"
 
-blk_t test_vec[] = { 8, 12, 24, 34, 43, 44, 100, 0 };
+blk64_t test_vec[] = { 8, 12, 24, 34, 43, 44, 100, 0 };
 
 ext2_filsys    test_fs;
 ext2fs_block_bitmap bad_block_map, touched_map;
@@ -181,14 +182,14 @@ static void check_map(void)
 
        for (i=0; test_vec[i]; i++) {
                if (ext2fs_test_block_bitmap2(touched_map, test_vec[i])) {
-                       printf("Bad block was touched --- %u\n", test_vec[i]);
+                       printf("Bad block was touched --- %llu\n", test_vec[i]);
                        failed++;
                        first_no_comma = 1;
                }
                ext2fs_mark_block_bitmap2(touched_map, test_vec[i]);
        }
        for (i = 0; i < test_fs->group_desc_count; i++) {
-               for (j=0, blk = test_fs->group_desc[i].bg_inode_table;
+               for (j=0, blk = ext2fs_inode_table_loc(test_fs, i);
                     j < test_fs->inode_blocks_per_group;
                     j++, blk++) {
                        if (!ext2fs_test_block_bitmap2(touched_map, blk) &&