Commit Graph

4554 Commits (35fbb698ba20a0d8f62c3e73efe09b3d767d394f)
 

Author SHA1 Message Date
Jean-Pierre André 35fbb698ba Fixed a bug when undeleting a sparse file
An old typo leading to a badly recovered file and sometimes to a segfault
2011-09-26 15:03:38 +02:00
Jean-Pierre André 08bf2b5bcb Avoided logging meaningless fixup errors in ntfsclone and ntfsresize
Logging of fixup errors for uninitialized inodes cause unnecessary
worries and suspicion of malfunctions in ntfs-3g. This patch silences
these loggings in ntfsclone and ntfsresize which have to analyze all
inodes, including the uninitialized ones.
2011-09-23 11:28:42 +02:00
Jean-Pierre André ad53f4c24a Enabled getting the sector size from an ioctl on FreeBSD and MacOSX (Erik Larsson)
The sector size is needed for formatting a volume unless forced through
an option or using the traditional sector size.
2011-09-14 12:21:59 +02:00
Jean-Pierre André 3c03e056f1 Fixed the size limits for the volume label set by mkntfs 2011-09-14 08:32:28 +02:00
Erik Larsson c3e651047a Replaced some usages of ntfs_mbstoucs_libntfscompat with ntfs_mbstoucs.
Some calls to ntfs_mbstoucs_libntfscompat were unnecessary as they only used
functionality that can be provided by ntfs_mbstoucs.
2011-09-13 09:51:55 +02:00
Erik Larsson 8d06955ea4 Cleaned up and moved label changing functionality into libntfs-3g.
The label changing code in ntfslabel was cleaned up and modified to use the more
advanced functionality of libntfs-3g instead of using older custom code to
resize and create resident attributes.
The core label changing functionality was also moved into the library so it can
be reused by other programs.
2011-09-13 09:43:30 +02:00
Jean-Pierre André 4dd63e0fd1 Fixed the setting of attributes by secaudit
The setting of attributes was done in the "standard information",
it must also be propagated to the indexes in parent directories.
2011-09-12 18:41:25 +02:00
Erik Larsson b8103bbcfe Permit $VOLUME_NAME to be 0-sized, even when $AttrDef says otherwise.
When clearing a volume name in Windows, $VOLUME_NAME is set to size 0, even if
the standard $AttrDef says that the minimum size is 2.

So the definition in $AttrDef doesn't reflect actual Windows behaviour in this
particular case, and to clear volume names ourselves the way Windows does it,
we must must add a special rule to permit us to truncate the $VOLUME_NAME
attribute to 0 even when $AttrDef specifies a higher value as minimum size.
2011-09-12 09:07:00 +02:00
Jean-Pierre André 178ae712c3 Fixed the truncation of dos file names
Truncate dos file names to 12 ntfschars instead of 12 utf-8 bytes
2011-09-08 09:52:51 +02:00
Jean-Pierre André 0b8b7521a4 Fixed the FullyMapped flag when making an attribute resident
When an attribute is truncated and made resident, the NAttrFullyMapped
flags has to be cleared, otherwise the attribute cannot be properly
mapped when the attribute is later made non-resident again.
2011-08-30 16:02:32 +02:00
Jean-Pierre André 0b827cc978 Avoid endless recursion when MFT extents are described in themselves
When getting extents of MFT, we must be sure they are in the MFT part which
has already been mapped, otherwise we fall into an endless recursion.

Situations have been met where extents locations are described in themselves,
as a consequence of a bug, probably unrelated to ntfs-3g.
This is a severe error which chkdsk cannot fix.
2011-08-30 15:56:36 +02:00
Jean-Pierre André a1161d552f cosmetic : Removed a pointless store in ntfs_attr_make_resident() (Fabian Keil) 2011-08-04 15:49:36 +02:00
Jean-Pierre André e4a7a56a1a cosmetic : Removed a redundant store in utils_is_metadata() (Fabian Keil) 2011-08-04 15:49:36 +02:00
Jean-Pierre André ae020fc4a7 cosmetic : Removed two dead stores in remove_object_id_index() (Fabian Keil) 2011-08-04 15:49:36 +02:00
Jean-Pierre André 35ad185ade cosmetic : Removed a pointless variable initialization in upgrade_secur_desc() (Fabian Keil) 2011-08-04 15:49:36 +02:00
Jean-Pierre André 246019fcd5 fix : Fixed ntfs_rl_extend() returning garbage in error case (Fabian Keil) 2011-08-04 15:49:36 +02:00
Jean-Pierre André 9497aa7974 minor : Fixed ntfs_fuse_read() returning garbage in error case (Fabian Keil) 2011-08-04 15:49:35 +02:00
Jean-Pierre André fa3d7a5728 minor : Fixed ntfs_upcase_build_default() returning garbage in error case (Fabian Keil) 2011-08-04 15:49:35 +02:00
Jean-Pierre André f10f067c7b revert : Reverted to old behavior for errored reply in ntfsresize 2011-08-04 15:49:35 +02:00
Jean-Pierre André a3579a1674 documentation : Improved the description of the -f option in the manual for ntfsresize 2011-08-04 15:49:35 +02:00
Jean-Pierre André 0147a15e1e cosmetic : Removed an unneeded function in fuse_lowlevel.c (and a gcc 4.6 warning) 2011-08-04 15:49:35 +02:00
Jean-Pierre André 12e54df513 cosmetic : Removed more unneeded variables warned by gcc 4.6 2011-08-04 15:49:35 +02:00
Erik Larsson 182c5c2a2f Fix: Forgot to update state bits after last change. 2011-08-03 15:49:40 +02:00
Erik Larsson 7f2d1efa82 Bugfix: ntfs_mft_load didn't fill in the size fields in the $MFT inode. 2011-08-03 11:13:40 +02:00
Erik Larsson 277c8c8cdf ntfsprogs/Makefile.am: Fix for conflicting usage of EXTRA_PROGRAMS.
After the '--enable-extras' patch, EXTRA_PROGRAMS and bin_PROGRAMS were both defined when ENABLE_EXTRAS was enabled.
This created a conflict, where at least automake 1.10 attempted to emit targets for the binaries twice, resulting in failure when running 'autogen.sh'.

Conflict was resolved by defining the names of the binaries in a non-reserved variable EXTRA_PROGRAM_NAMES, which is then included either in EXTRA_PROGRAMS or bin_PROGRAMS but never in both.
2011-07-06 19:11:49 +02:00
Erik Larsson fd71e36096 Added a new configure option '--disable-ntfs-3g'.
The binaries 'ntfs-3g', 'lowntfs-3g', 'ntfs-3g.probe' 'ntfs-3g.usermap' and 'ntfs-3g.secaudit' will not be built when this option is passed to 'configure'.

When specifying both '--disable-ntfsprogs' and '--disable-ntfs-3g', only libntfs-3g will be built (no executable binaries).
2011-07-06 19:11:42 +02:00
Jean-Pierre André 2cc1bcb59d Fixed compiling ntfsfix.c for a Sparc 2011-07-06 17:46:31 +02:00
Jean-Pierre André de151c1add Implemented a new option to clear the list of bad sectors 2011-07-05 12:17:31 +02:00
Jean-Pierre André 919eeb71df Improved compression (faster) 2011-07-05 12:17:30 +02:00
Jean-Pierre André d7926f72d0 Provided support for big writes 2011-07-05 12:17:30 +02:00
Jean-Pierre André 17caba34db Implemented expanding runlists in ntfsresize (Fedora 689275) 2011-07-05 12:17:30 +02:00
Jean-Pierre André bde75a7bce Optionally closed volume and cleaned memory when leaving ntfsresize (kept disabled) 2011-07-05 12:17:30 +02:00
Jean-Pierre André c54db11d96 Fixed dead http links in ntfsprogs manuals (Daniel Baumann) 2011-07-05 12:17:30 +02:00
Jean-Pierre André 1673ce9c91 Accepted the backup bootsector not be to accounted for when cloning 2011-07-05 12:17:29 +02:00
Jean-Pierre André 5a56ad9ff1 Silenced apparent out-of-range subscripts warned by gcc 4.6 2011-07-05 12:17:29 +02:00
Jean-Pierre André 5cd49257b0 Removed unneeded variables as warned by gcc 4.6 2011-07-05 12:17:29 +02:00
Jean-Pierre André 1c1c0540e8 Fixed use of uninitialized variable in ntfsfix 2011-07-05 12:17:29 +02:00
Jean-Pierre André 2be8e64049 Fixed relatime as a default mount option (had become atime) 2011-07-05 12:17:29 +02:00
Jean-Pierre André 47a4b0ba17 Fixed a too restrictive consistency check in attrib.c 2011-07-05 12:17:29 +02:00
Jean-Pierre André f5433e02a2 Fixed the description of inherit option in the manual 2011-07-05 12:17:28 +02:00
Jean-Pierre André 2c248202f5 Fixed accessing an unmounted volume in ntfsck 2011-07-05 12:17:28 +02:00
Jean-Pierre André 0ec31405c6 Fixed casting data to printf format in ntfsck, ntfsmove and ntfswipe 2011-07-05 12:17:28 +02:00
Jean-Pierre André fe1a7b22a2 Fixed checking file system type in ntfsck 2011-07-05 12:17:28 +02:00
Jean-Pierre André 473d03d4b7 Fixed a bug causing SEGV in ntfsck (but nothing done anyway) 2011-07-05 12:17:28 +02:00
Jean-Pierre André 44116675ca Fixed warning for possible use of uninitialized variable in ntfsfix 2011-07-05 12:17:28 +02:00
Jean-Pierre André 262ed5f7df Cleared attribute flags controlling recursive writes 2011-07-05 12:17:28 +02:00
Jean-Pierre André 571dbc5784 Fixed device path canonicalization for use by devmapper (basilinya)
For some reason, when the monted device is "/dev/mapper/*", a record
in the form "/dev/dm-*" ends up in /etc/mtab and the device cannot be
unmounted.

The reason is unclear, the /dev/mapper name is not a symlink, and the
function doing the name change is not known. No detailed feedback from
the users having met the issue.

The patch changes the name back to the /dev/mapper name after realpath()
is called, and, if there is an actual change, both the name passed to
ntfs-3g and the one passed to fuse and mount are logged in the hope
of getting a clue about what is happening.

But ntfs-3g is probably not the right place for a fix.
2011-07-05 12:17:12 +02:00
Jean-Pierre André 82b00364a8 Fixed setting DOS names when defined with lower-case chars 2011-07-05 12:17:11 +02:00
Jean-Pierre André 5aa84db792 Silenced warning for ignoring the result of fgets in ntfsresize 2011-07-05 12:17:11 +02:00
Jean-Pierre André 683d0a0a4f Defined an option --enable-extras for extra ntfsprogs tools (from Fedora) 2011-07-05 12:17:11 +02:00