[Ocfs2-tools-commits] mfasheh commits r1379 - branches/sparse-files/debugfs.ocfs2

svn-commits at oss.oracle.com svn-commits at oss.oracle.com
Tue Aug 14 15:28:39 PDT 2007


Author: mfasheh
Date: 2007-08-14 15:28:39 -0700 (Tue, 14 Aug 2007)
New Revision: 1379

Modified:
   branches/sparse-files/debugfs.ocfs2/dump.c
Log:
ocfs2-tools/sparse-files: always print empty extent records

We want to be explicit in debugfs and print all extent records within
l_next_free_rec, even empty ones.

The non e_clusters fields within the record may contain interesting
information that could be used when tracking down bugs.

Additionally, it gets a little confusing if debugfs randomly starts the
array at one or zero.

Signed-off-by: Tao Ma <tao.ma at oracle.com>


Modified: branches/sparse-files/debugfs.ocfs2/dump.c
===================================================================
--- branches/sparse-files/debugfs.ocfs2/dump.c	2007-08-14 01:07:29 UTC (rev 1378)
+++ branches/sparse-files/debugfs.ocfs2/dump.c	2007-08-14 22:28:39 UTC (rev 1379)
@@ -303,11 +303,6 @@
 	for (i = 0; i < ext->l_next_free_rec; ++i) {
 		rec = &(ext->l_recs[i]);
 		clusters = ocfs2_rec_clusters(ext->l_tree_depth, rec);
-		/* For a sparse file, we may find an empty record.
-		 * Just skip it.
-		 */
-		if (!clusters)
-			continue;
 		fprintf(out, "\t%-2d %-11u   %-12u   %"PRIu64"\n",
 		       	i, rec->e_cpos, clusters, rec->e_blkno);
 	}




More information about the Ocfs2-tools-commits mailing list