Whamcloud - gitweb
po: update sr.po (from translationproject.org)
[tools/e2fsprogs.git] / e2fsck / scantest.c
index ed586b1..ed3595f 100644 (file)
@@ -2,6 +2,7 @@
  * scantest.c - test the speed of the inode scan routine
  */
 
+#include "config.h"
 #include <string.h>
 #include <fcntl.h>
 #include <ctype.h>
@@ -11,9 +12,6 @@
 #include <getopt.h>
 #endif
 #include <unistd.h>
-#ifdef HAVE_MNTENT_H
-#include <mntent.h>
-#endif
 #include <sys/ioctl.h>
 #ifdef HAVE_MALLOC_H
 #include <malloc.h>
@@ -78,8 +76,8 @@ static void print_resource_track(struct resource_track *track)
        gettimeofday(&time_end, 0);
        getrusage(RUSAGE_SELF, &r);
 
-       printf(_("Memory used: %d, elapsed time: %6.3f/%6.3f/%6.3f\n"),
-              (int) (((char *) sbrk(0)) - ((char *) track->brk_start)),
+       printf(_("Memory used: %lu, elapsed time: %6.3f/%6.3f/%6.3f\n"),
+              (unsigned long)((char *)sbrk(0) - (char *)track->brk_start),
               timeval_subtract(&time_end, &track->time_start),
               timeval_subtract(&r.ru_utime, &track->user_start),
               timeval_subtract(&r.ru_stime, &track->system_start));
@@ -135,7 +133,7 @@ int main (int argc, char *argv[])
        }
 
 
-       ext2fs_close(fs);
+       ext2fs_close_free(&fs);
 
        print_resource_track(&global_rtrack);