From: Eric Sandeen <sandeen@redhat.com>
To: ext4 development <linux-ext4@vger.kernel.org>
Subject: [PATCH] libext2fs: last of the incorrect direct group_desc accesses
Date: Thu, 03 Sep 2009 16:02:04 -0500 [thread overview]
Message-ID: <4AA02ECC.4010101@redhat.com> (raw)
This should be, I hope, the last of the fixes for accessing
the group descriptors directly in libext2fs, at least.
Soon we should make it opaque to avoid this mess.
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
Index: e2fsprogs/lib/ext2fs/openfs.c
===================================================================
--- e2fsprogs.orig/lib/ext2fs/openfs.c
+++ e2fsprogs/lib/ext2fs/openfs.c
@@ -355,7 +355,7 @@ errcode_t ext2fs_open2(const char *name,
for (group = 0; group < fs->group_desc_count; group++) {
ext2fs_bg_flag_clear(fs, group, EXT2_BG_BLOCK_UNINIT);
ext2fs_bg_flag_clear(fs, group, EXT2_BG_INODE_UNINIT);
- fs->group_desc[group].bg_itable_unused = 0;
+ ext2fs_bg_itable_unused_set(fs, group, 0);
}
ext2fs_mark_super_dirty(fs);
}
Index: e2fsprogs/e2fsck/pass2.c
===================================================================
--- e2fsprogs.orig/e2fsck/pass2.c
+++ e2fsprogs/e2fsck/pass2.c
@@ -1003,7 +1003,7 @@ out_htree:
} else if (dirent->inode >= first_unused_inode) {
pctx.num = dirent->inode;
if (fix_problem(ctx, PR_2_INOREF_IN_UNUSED, &cd->pctx)){
- fs->group_desc[group].bg_itable_unused = 0;
+ ext2fs_bg_itable_unused_set(fs, group, 0);
ext2fs_mark_super_dirty(fs);
ctx->flags |= E2F_FLAG_RESTART_LATER;
} else {
next reply other threads:[~2009-09-03 21:02 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-03 21:02 Eric Sandeen [this message]
2009-09-06 16:42 ` [PATCH] libext2fs: last of the incorrect direct group_desc accesses Theodore Tso
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4AA02ECC.4010101@redhat.com \
--to=sandeen@redhat.com \
--cc=linux-ext4@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.