+1999-10-22 <tytso@valinux.com>
+
+ * pass2.c (check_filetype): If the filetype filesystem feature is
+ not set, and a directory entry has a dirent feature, offer
+ to clear it (since 2.0 kernels will do complain will
+ interpret it as a very large name length field).
+
+ * problem.c (PR_2_CLEAR_FILETYPE): Add new problem code.
+
1999-10-21 <tytso@valinux.com>
* e2fsck.8.in: Update man page to use a more standard format (bold
struct ext2_inode inode;
if (!(ctx->fs->super->s_feature_incompat &
- EXT2_FEATURE_INCOMPAT_FILETYPE))
- return 0;
+ EXT2_FEATURE_INCOMPAT_FILETYPE)) {
+ if (filetype == 0 ||
+ !fix_problem(ctx, PR_2_CLEAR_FILETYPE, pctx))
+ return 0;
+ dirent->name_len = dirent->name_len & 0xFF;
+ return 1;
+ }
if (ext2fs_test_inode_bitmap(ctx->inode_dir_map, dirent->inode)) {
should_be = EXT2_FT_DIR;
"@E has an incorrect filetype (was %dt, should be %N)\n",
PROMPT_FIX, 0 },
+ /* Directory filetype set on filesystem */
+ { PR_2_CLEAR_FILETYPE,
+ "@E has filetype set\n",
+ PROMPT_CLEAR, PR_PREEN_OK },
+
/* Pass 3 errors */
/* Pass 3: Checking directory connectivity */
/* Directory filetype incorrect */
#define PR_2_BAD_FILETYPE 0x020028
+/* Directory filetype set when it shouldn't be */
+#define PR_2_CLEAR_FILETYPE 0x020029
+
/*
* Pass 3 errors
*/