problem.c, problem.h (PR_0_HURD_CLEAR_FILETYPE): Add new problem code.
super.c (check_super_block): If the OS type in the superblock is the
Hurd, check to see if the filetype feature is set, and offer to clear
it if so. This needs to be done since the Hurd doesn't properly
support the filetype feature. (And since the hurd allows the
transmogrification of files to special files and vice versa --- for no
good reason that I can understand --- it can't support the filetype
feature for the forseeable future, either.)
ChangeLog, mke2fs.c:
mke2fs.c (main): We forcibly turn off the filetype feature if the OS
is the hurd, since the hurd doesn't support it. (And since the hurd
allows the transmogrification of files to special files and vice versa
--- for no good reason that I can understand --- it can't support the
filetype feature for the forseeable future, either.)
mke2fs.c (proceed_question): Fix reversed sense of proceed_question
that was busted due to the internationalization patch. Fixed bug
where if proceed_question was called twice, the input buffer wasn't
cleared of the previous question's newline.
ChangeLog, expect.1, expect.2, image.gz, name:
f_hurd: Add test for Hurd-specific features (right now, just checks to
make sure the filetype feature is cleared)
ChangeLog, ls.c:
ls.c (list_super): Change the string displayed for the Hurd to be
GNU/Hurd, instead of just "GNU".
+2000-05-08 Theodore Ts'o <tytso@valinux.com>
+
+ * problem.c, problem.h (PR_0_HURD_CLEAR_FILETYPE): Add new problem
+ code.
+
+ * super.c (check_super_block): If the OS type in the superblock is
+ the Hurd, check to see if the filetype feature is set, and
+ offer to clear it if so. This needs to be done since the
+ Hurd doesn't properly support the filetype feature.
+ (And since the hurd allows the transmogrification of files
+ to special files and vice versa --- for no good reason
+ that I can understand --- it can't support the filetype
+ feature for the forseeable future, either.)
+
2000-04-03 Theodore Ts'o <tytso@valinux.com>
* unix.c: For platforms that don't define optarg.h, manually
/* Inode count in superblock is incorrect */
{ PR_0_INODE_COUNT_WRONG,
- N_("@i count in @S is %i, should be %j\n"),
+ N_("@i count in @S is %i, should be %j.\n"),
PROMPT_FIX, 0 },
-
+
+ { PR_0_HURD_CLEAR_FILETYPE,
+ N_("The Hurd does not support the filetype feature.\n"),
+ PROMPT_CLEAR, 0 },
+
/* Pass 1 errors */
/* Pass 1: Checking inodes, blocks, and sizes */
/* Inode count in the superblock incorrect */
#define PR_0_INODE_COUNT_WRONG 0x00000D
+/* The Hurd does not support the filetype feature */
+#define PR_0_HURD_CLEAR_FILETYPE 0x00000E
+
/*
* Pass 1 errors
*/
ext2fs_mark_super_dirty(fs);
}
+ clear_problem_context(&pctx);
+
#ifndef EXT2_SKIP_UUID
/*
* If the UUID field isn't assigned, assign it.
*/
if (!(ctx->options & E2F_OPT_READONLY) && uuid_is_null(s->s_uuid)) {
- clear_problem_context(&pctx);
if (fix_problem(ctx, PR_0_ADD_UUID, &pctx)) {
uuid_generate(s->s_uuid);
ext2fs_mark_super_dirty(fs);
}
}
#endif
+
+ /*
+ * For the Hurd, check to see if the filetype option is set,
+ * since it doesn't support it.
+ */
+ if (fs->super->s_creator_os == EXT2_OS_HURD &&
+ (fs->super->s_feature_incompat &
+ EXT2_FEATURE_INCOMPAT_FILETYPE)) {
+ if (fix_problem(ctx, PR_0_HURD_CLEAR_FILETYPE, &pctx)) {
+ fs->super->s_feature_incompat &=
+ ~EXT2_FEATURE_INCOMPAT_FILETYPE;
+ ext2fs_mark_super_dirty(fs);
+
+ }
+ }
return;
}
-
+2000-05-08 Theodore Ts'o <tytso@valinux.com>
+
+ * ls.c (list_super): Change the string displayed for the Hurd to
+ be GNU/Hurd, instead of just "GNU".
+
Thu Apr 6 17:38:00 2000 Theodore Y. Ts'o <tytso@signal.thunk.org>
* feature.c: Make feature_list static; it shouldn't be exported.
printf ("\n");
switch (s->s_creator_os) {
case EXT2_OS_LINUX: os = "Linux"; break;
- case EXT2_OS_HURD: os = "GNU"; break;
+ case EXT2_OS_HURD: os = "GNU/Hurd"; break;
case EXT2_OS_MASIX: os = "Masix"; break;
default: os = "unknown"; break;
}
+2000-05-08 Theodore Ts'o <tytso@valinux.com>
+
+ * mke2fs.c (main): We forcibly turn off the filetype feature if
+ the OS is the hurd, since the hurd doesn't support it.
+ (And since the hurd allows the transmogrification of files
+ to special files and vice versa --- for no good reason
+ that I can understand --- it can't support the filetype
+ feature for the forseeable future, either.)
+
+ * mke2fs.c (proceed_question): Fix reversed sense of
+ proceed_question that was busted due to the
+ internationalization patch. Fixed bug where if
+ proceed_question was called twice, the input buffer wasn't
+ cleared of the previous question's newline.
+
Thu Apr 6 17:50:25 2000 Theodore Y. Ts'o <tytso@signal.thunk.org>
* badblocks.c (flush_bufs): Use fsync() if the system doesn't
static void proceed_question(NOARGS)
{
- int c;
+ char buf[256];
char *short_yes = _("yY");
fflush(stdout);
fflush(stderr);
printf(_("Proceed anyway? (y,n) "));
- c = getchar();
- if (strchr(short_yes, (char) c))
+ buf[0] = 0;
+ fgets(buf, sizeof(buf), stdin);
+ if (strchr(short_yes, buf[0]) == 0)
exit(1);
}
}
/*
+ * For the Hurd, we will turn off filetype since it doesn't
+ * support it.
+ */
+ if (fs->super->s_creator_os == EXT2_OS_HURD)
+ fs->super->s_feature_incompat &=
+ ~EXT2_FEATURE_INCOMPAT_FILETYPE;
+
+ /*
* Set the volume label...
*/
if (volume_label) {
+2000-05-08 Theodore Ts'o <tytso@valinux.com>
+
+ * f_hurd: Add test for Hurd-specific features (right now, just
+ checks to make sure the filetype feature is cleared)
+
2000-04-06 Theodore Ts'o <tytso@valinux.com>
* f_filetype: Updated expect script to match with new text for
--- /dev/null
+The Hurd does not support the filetype feature.
+Clear? yes
+
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 11/16 files (0.0% non-contiguous), 20/100 blocks
+Exit status is 1
--- /dev/null
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+test_filesys: 11/16 files (0.0% non-contiguous), 20/100 blocks
+Exit status is 0
--- /dev/null
+GNU/Hurd specific tests