Whamcloud - gitweb
badblocks.c (bb_output): Flush output to the badblocks
authorTheodore Ts'o <tytso@mit.edu>
Thu, 3 Apr 2003 16:37:46 +0000 (11:37 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 3 Apr 2003 16:37:46 +0000 (11:37 -0500)
output file as bad blocks are discovered.

misc/ChangeLog
misc/badblocks.c

index f5e0de7..6815171 100644 (file)
@@ -1,3 +1,8 @@
+2003-04-03  Theodore Ts'o  <tytso@mit.edu>
+
+       * badblocks.c (bb_output): Flush output to the badblocks
+               output file as bad blocks are discovered.
+
 2003-03-25  Theodore Ts'o  <tytso@mit.edu>
 
        * chattr.1.in: Clarified the description of the 't' (no tail) 
index c6e308e..ba3db87 100644 (file)
@@ -87,7 +87,8 @@ static int bb_output (unsigned long bad)
        if (ext2fs_badblocks_list_test(bb_list, bad))
                return 0;
 
-       fprintf (out, "%lu\n", bad);
+       fprintf(out, "%lu\n", bad);
+       fflush(out);
 
        errcode = ext2fs_badblocks_list_add (bb_list, bad);
        if (errcode) {