From db92f7bfbf2982ad92135a690b5d7be5a1a5cfbf Mon Sep 17 00:00:00 2001 From: "(none)!yura" <(none)!yura> Date: Sun, 10 Oct 2004 17:20:48 +0000 Subject: [PATCH] - add new 0 length fields to ATTR_RECORD, they can be used to get size of attribute (Logical change 1.599) --- include/ntfs/layout.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/ntfs/layout.h b/include/ntfs/layout.h index 26c8f81f..5e094496 100644 --- a/include/ntfs/layout.h +++ b/include/ntfs/layout.h @@ -709,6 +709,9 @@ typedef struct { /* 22 */ RESIDENT_ATTR_FLAGS resident_flags; /* See above. */ /* 23 */ s8 reservedR; /* Reserved/alignment to 8-byte boundary. */ +/* 24 */ void *resident_attr_end[0]; /* Use offsetof( + ATTR_RECORD, resident_attr_end) to + get size of resident attribute. */ } __attribute__ ((__packed__)); /* Non-resident attributes. */ struct { @@ -752,12 +755,19 @@ typedef struct { /* 56*/ s64 initialized_size; /* Byte size of initialized portion of the attribute value. Usually equals data_size. */ +/* 64 */ void *non_resident_attr_end[0]; /* Use offsetof( + ATTR_RECORD, non_resident_attr_end) to + get size of non resident attribute. */ /* sizeof(uncompressed attr) = 64*/ /* 64*/ s64 compressed_size; /* Byte size of the attribute value after compression. Only present when compressed. Always is a multiple of the cluster size. Represents the actual amount of disk space being used on the disk. */ +/* 72 */ void *compressed_non_resident_attr_end[0]; + /* Use offsetof(ATTR_RECORD, + compressed_non_resident_attr_end) to get size + of non resident compressed attribute. */ /* sizeof(compressed attr) = 72*/ } __attribute__ ((__packed__)); } __attribute__ ((__packed__));