Changes by: szaka
Update of /cvsroot/linux-ntfs/ntfsprogs/ntfsprogs
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7627
Modified Files:
mkntfs.c
Log Message:
Create files in $Extend in the same order as 'format' does. This shouldn't
actually matter but it makes ntfscmp happier and helps great deal to catch
easily incorrectly created volumes.
Index: mkntfs.c
===================================================================
RCS file: /cvsroot/linux-ntfs/ntfsprogs/ntfsprogs/mkntfs.c,v
retrieving revision 1.88
retrieving revision 1.89
diff -u -p -r1.88 -r1.89
--- mkntfs.c 2 Nov 2005 21:03:29 -0000 1.88
+++ mkntfs.c 2 Nov 2005 23:14:39 -0000 1.89
@@ -4794,47 +4794,47 @@ static void mkntfs_create_root_structure
if (vol->major_ver >= 3) {
extend_flags = FILE_ATTR_HIDDEN | FILE_ATTR_SYSTEM |
FILE_ATTR_DUP_VIEW_INDEX_PRESENT;
- Vprintf("Creating $ObjId (mft record 24)\n");
+ Vprintf("Creating $Quota (mft record 24)\n");
m = (MFT_RECORD*)(buf + 24 * vol->mft_record_size);
m->flags |= MFT_RECORD_IS_4;
m->flags |= MFT_RECORD_IS_8;
if (!err)
err = create_hardlink_res((MFT_RECORD*)(buf +
- 11 * vol->mft_record_size), extend_ref,
- m, MK_LE_MREF(24, 24), 0LL, 0LL,
- extend_flags, 0, 0, "$ObjId",
- FILE_NAME_WIN32_AND_DOS);
-
+ 11 * vol->mft_record_size), extend_ref, m,
+ MK_LE_MREF(24, 24), 0LL, 0LL, extend_flags
+ , 0, 0, "$Quota", FILE_NAME_WIN32_AND_DOS);
// FIXME: This should be IGNORE_CASE
if (!err)
err = add_attr_index_root(m, "$O", 2, 0, AT_UNUSED,
- COLLATION_NTOFS_ULONGS, opts.index_block_size);
+ COLLATION_NTOFS_SID, opts.index_block_size);
+ // FIXME: This should be IGNORE_CASE
if (!err)
- err = initialize_objid(m, volume_obj_id->object_id,
- MK_LE_MREF(FILE_Volume, FILE_Volume));
+ err = add_attr_index_root(m, "$Q", 2, 0, AT_UNUSED,
+ COLLATION_NTOFS_ULONG, opts.index_block_size);
+ if (!err)
+ err = initialize_quota(m);
if (err < 0)
- err_exit("Couldn't create $ObjId: %s\n", strerror(-err));
- Vprintf("Creating $Quota (mft record 25)\n");
+ err_exit("Couldn't create $Quota: %s\n", strerror(-err));
+ Vprintf("Creating $ObjId (mft record 25)\n");
m = (MFT_RECORD*)(buf + 25 * vol->mft_record_size);
m->flags |= MFT_RECORD_IS_4;
m->flags |= MFT_RECORD_IS_8;
if (!err)
err = create_hardlink_res((MFT_RECORD*)(buf +
- 11 * vol->mft_record_size), extend_ref, m,
- MK_LE_MREF(25, 25), 0LL, 0LL, extend_flags
- , 0, 0, "$Quota", FILE_NAME_WIN32_AND_DOS);
+ 11 * vol->mft_record_size), extend_ref,
+ m, MK_LE_MREF(25, 25), 0LL, 0LL,
+ extend_flags, 0, 0, "$ObjId",
+ FILE_NAME_WIN32_AND_DOS);
+
// FIXME: This should be IGNORE_CASE
if (!err)
err = add_attr_index_root(m, "$O", 2, 0, AT_UNUSED,
- COLLATION_NTOFS_SID, opts.index_block_size);
- // FIXME: This should be IGNORE_CASE
- if (!err)
- err = add_attr_index_root(m, "$Q", 2, 0, AT_UNUSED,
- COLLATION_NTOFS_ULONG, opts.index_block_size);
+ COLLATION_NTOFS_ULONGS, opts.index_block_size);
if (!err)
- err = initialize_quota(m);
+ err = initialize_objid(m, volume_obj_id->object_id,
+ MK_LE_MREF(FILE_Volume, FILE_Volume));
if (err < 0)
- err_exit("Couldn't create $Quota: %s\n", strerror(-err));
+ err_exit("Couldn't create $ObjId: %s\n", strerror(-err));
Vprintf("Creating $Reparse (mft record 26)\n");
m = (MFT_RECORD*)(buf + 26 * vol->mft_record_size);
m->flags |= MFT_RECORD_IS_4;
|