nt_io.c (_OpenNtName): Open the device using
FILE_SYNCHRONOUS_IO_NONALERT instead of FILE_SYNCHRONOUS_IO_ALERT
(nt_open): At the end of the device open routine, unlock the drive but
do not dismount it.
mke2fs.c (PRS): Use __u64 instead of long long for portability
reasons.
Moved #include of sys/stat.h inside #ifdef HAVE_LINUX_MAJOR_H for
portability reasons.
ChangeLog, util.c:
util.c: For NT portability, don't redefine getchar(), since stdio
defines that. Instead we introduce a new abstract macro read_a_char()
which is #defined to the right function as necessary.
ext2_fs.h (i_reserved2): Use __GNU__ instead of __hurd__ to detect the
Hurd OS. To protect against future irrationality on the part of the
FSF concerning whether Linux is GNU or not, on a system which defines
both __linux__ and __GNU___, __linux__ takes precedence.
ChangeLog, initialize.c:
initialize.c (CREATOR_OS): Use __GNU__ instead of __gnu__ to detect
the Hurd OS.
ChangeLog, debugfs.c:
debugfs.c (do_dirty_filesys): Make the "dirty" command clear the valid
bit on the superblock. (And with a -clean option to set the valid
bit.) Originally it was used just to set the "needs to be written"
bit in the in-core version of the fs structure.
fsck.c (execute): Fix really stupid bug in the linked list management
which caused fsck in parallel mode to go into an infinite loop.
ChangeLog, mke2fs.c:
mke2fs.c (show_stats): Capitalized Hurd to make the GNU types happy.
ChangeLog, configure.in:
configure.in: Capitalized Hurd to make the GNU folks happy.
problem.c, problem.h (PR_2_NULL_NAME): Add new problem code.
pass2.c (check_dir_block): Require that the length of the directory
entry be at least 12 bytes. Check to see if the filename is
zero-length, and flag that as an error.
Update to pass new required parameter to e2p_edit_features
mke2fs.8.in:
Update man page to add explanatory note about how the default block
size is determined.
tune2fs.c (main): Add a new option -O which allows the user to set and
clear certain "safe" filsystem feature flags. Currently, the only
ones which are supported for modification are sparse_superblock and
filetype.
mke2fs.c (PRS): Add new option -O which allows the user to request
filesystems with specific filesystem options. By default on 2.2 and
later systems, create filesystems that have both file type information
and sparse superblocks.
feature.c (e2p_edit_feature), e2p.h: Add a new argument which allows
the calling application to limit what features the user is allowed to
set or clear using this function. Also add support for comma
separated lists.
mkdir.c (ext2fs_mkdir): Pass EXT2_FT_DIR flag to ext2fs_link().
link.c (ext2fs_link): This call now uses the low three bits of the
flags parameter to pass the directory filetype information; it will
set the directory entry FILETYPE information if the filesystem
supports it.
newdir.c (ext2fs_new_dir_block): If the FILETYPE superblock option is
set, then create the '.' and '..' entries with the filetype set to
EXT2_FT_DIR.
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).
badblocks.8.in, chattr.1.in, dumpe2fs.8.in, e2label.8.in,
fsck.8.in, lsattr.1.in, mke2fs.8.in, mklost+found.8.in,
tune2fs.8.in, uuidgen.1.in: Update man page to use a more standard
format (bold option flags and italicized variables), as suggested by
Andreas Dilger (adilger@enel.ucalgary.ca)
ChangeLog, e2fsck.8.in:
e2fsck.8.in: Update man page to use a more standard format (bold
option flags and italicized variables), as suggested by Andreas Dilger
(adilger@enel.ucalgary.ca)
ChangeLog, uuid_generate.3.in:
uuid_generate.8.in: Update man page to use a more standard format
(bold option flags and italicized variables), as suggested by Andreas
Dilger (adilger@enel.ucalgary.ca)
pass4.c (e2fsck_pass4): If an inode is set in the inode_imagic_map
bitmap, don't check to see if it is disconnected from the inode tree
(because it almost certainly will be). Free inode_imagic_map at the
end of pass 4.
pass2.c (check_dir_block, check_filetype): If the FILETYPE feature is
set, check the directory entry's filetype information field, and
fix/set it if necessary. (e2fsck_pass2): Free the inode_reg_map
bitmap at the end of pass 2.
pass1.c (e2fsck_pass1, alloc_imagic_map): Allocate and fill in
information for inode_reg_map and inode_imagic_map, which indicates
which inodes are regular files and AFS inodes, respectively.
Since only the master superblock is written during a restart, force
that superblock to be used after a restart; otherwise changes to the
block group descriptors end up getting ignored.
problem.c, problemP.h: If e2fsck is run -n, make def_yn variable be 0
for "no". Add support for a new flag, PR_NO_NOMSG, which supresses
the problem message if e2fsck is run with the -n option.
problem.c, problem.h (PR_2_SET_FILETYPE, PR_2_BAD_FILETYPE): Add new
problem codes.
message.c (expand_dirent_expression): Add support for %dt which prints
the dirent type information.
e2fsck.c (e2fsck_reset_context): Free new bitmaps (inode_reg_map and
inode_imagic_map).
e2fsck.h (e2fsck_t): Add new inode_reg_map and inode_magic_map to the
context structure.
ChangeLog, nt_io.c:
nt_io.c: New file which supports I/O under Windows NT.
ChangeLog, gen_uuid_nt.c:
gen_uuid_nt.c: New file which creates a UUID under Windows NT.
Many files:
Add support for non-Unix compiles
* configure.in (HAVE_STATE_FLAGS): Check to see if st_flags is
actually useful (since glibc 2.1 declares it on Alpha without
it being usable). Add check for signal.h header file, which
doesn't exist on non-unix platforms.
fsck.c (wait_one): If the fsck process just started, wait a second
before sending a SIGUSR1, to give it a chance to set the signal
handler; otherwise, fsck will die on an unhandled SIGUSR1.
debugfs.c, debug_cmds.ct: Add new debugfs command "feature" which
allows the user to set or clear filesystme features. Add the -f
(force) option to the open command. Add the -h (superblock header
only) option to the stats command.
ext2fs.h: Add new fields for journalling and define new feature bits
used by newer filesystems: IMAGIC_INODES, HAS_JOURNAL, RECOVER.
expanddir.c (ext2fs_expand_dir, expand_dir_proc): Change where we
update the inode block count and size files so that the block count
field is updated correctly when we create an indirect block.
Makefile.in, feature.c, e2p.h: New file which is used for displaying
and editing superblock feature sets.
ls.c (print_features, list_super): Add new function print_features
which is used to display the feature bits in the superblock.
partinfo.c: Fix minor compilation bugs pointed out by Yann Dirson.
mke2fs.c: Don't turn on sparse superblocks by default on pre-2.2 kernels.
mke2fs.8.in: Add the possible valid block sizes for mke2fs. Document
the -n flag, and the new defaults for the -s flag.
dumpe2fs.c, dumpe2fs.8.in: Add new options -f (force) and -h (header-only).
mke2fs.c (PRS): Fix logic for turning on/off the sparse superblock option.
Many files:
Updated copyright statements to reflect the GPL with permission of the
original authors.
pass1b.c (clone_file_block): Don't clear the dup_map flag if the block
also shares data with the fs metadata when the count drops to 1, since
the block should still be cloned, as fs metadata isn't included in the
count.
ChangeLog, pass3.c:
pass3.c (adjust_inode_count): Fix bug where we didn't keep the
internal and external inode counts in sync when we decremented an
inode whose link count was already zero. Now we skip incrementing or
decrementing both link counts if we would cause an overflow condition.
(expand_dir, expand_dir_proc): Change where we update the inode block
count and size files so that the block count field is updated
correctly when we create an indirect block.
f_expand: Make test case better by testing increasing the size of
lost+found where an indirect block must be created. Also add checks
to see what happens when directories are disconnected because their
containing directory is destroyed (turned into a socket :-)
f_dupfsblks: Add additional test cases where files share duplicate
blocks with both other files and filesystem metadata.
debugfs.c (dump_inode): Fix debugfs message so it is the same for when
compiled under either Linux 2.2 or 2.3. This allows for the f_swapfs
regression test suite to work regardless of which OS e2fsprogs was
compiled on.
Add flushb to list of files which are removed when doing a make clean.
Add a distclean production which removes Makefile
Add the doc substree to the clean and distclean rules.
depfix.sed: Remove all line continuations from the dependencies; the
word wrapping is now done by wordwrap.pl.
README, RELEASE-NOTES, TODO, e2fsprogs.spec:
Update for 1.15 release.
* mke2fs.c (PRS, set_fs_defaults): Add new option -T which allows the
user to specify the how the filesystem is to be used. Mke2fs now
chooses the filesystem parameters automatically based on the size of
the filesystem and the intended use of the filesystem. Add new option
-n which simply goes through the calculations to determine the
parameters of the filesystem the system would make.
* fsck.c, fsck.h: Add support for new option -C. This option will
automatically manage e2fsck processes so that they will print
completion/progress bars. If multiple filesystems are being checked,
arrange to make sure that only one e2fsck process is displaying a
progress bar at a time.
unix.c: Add support for calculating a progress bar if the -C0 option
is given. The function e2fsck_clear_progbar() clears the progress bar
and must be called before any message is issued. SIGUSR1 will enable
the progress bar, and SIGUSR2 will disable the progress bar. This is
used by fsck to handle parallel filesystem checks. Also, set the
device_name from the filesystem label if it is available.
e2fsck.h: Add new flags E2F_FLAG_PROG_BAR and E2F_FLAG_PROG_SUPRESS.
Add new field in the e2fsck structure which contains the last tenth of
a percent printed for the user.
message.c (print_e2fsck_message): Add call to e2fsck_clear_progbar().
pass1.c (e2fsck_pass1):
pass2.c (e2fsck_pass2):
pass3.c (e2fsck_pass3):
pass4.c (e2fsck_pass4):
pass5.c (e2fsck_pass5): Add call to e2fsck_clear_progbar when printing
the resource tracking information.
pass5.c (check_block_bitmaps, check_inode_bitmaps): If there is an
error in the bitmaps, suppress printing the progress bar using the
suppression flag for the remainder of the check, in order to clean up
the display.
badblocks.c (do_test): Don't complain if the write error occurs on a
non-block boundary. This is perfectly common when using blocksizes
larger than 1k.