Whamcloud - gitweb
git://git.whamcloud.com
/
tools
/
e2fsprogs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5d5e01d
)
filefrag: fix frag count in bmap case
author
Eric Sandeen
<sandeen@redhat.com>
Thu, 6 Aug 2009 02:43:23 +0000
(21:43 -0500)
committer
Theodore Ts'o
<tytso@mit.edu>
Sun, 16 Aug 2009 03:52:00 +0000
(23:52 -0400)
The fragmentation count in the bmap case seems to be
off by one:
/mnt/test/bar: 0 extents found
Addresses-Debian-Bug: #540376
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
misc/filefrag.c
patch
|
blob
|
history
diff --git
a/misc/filefrag.c
b/misc/filefrag.c
index
a2075e1
..
7f274f9
100644
(file)
--- a/
misc/filefrag.c
+++ b/
misc/filefrag.c
@@
-344,6
+344,8
@@
static void frag_report(const char *filename)
rc = get_bmap(fd, i, &block);
if (block == 0)
continue;
+ if (!num_extents)
+ num_extents++;
count++;
if (last_block && (block != last_block+1) ) {
if (verbose)