Add gcc_struct to all packed structures when compiling with mingw.
Just "packed" doesn't always pack the way we expect.
This commit is contained in:
parent
ae8159b9ca
commit
7e47e27bd8
105 changed files with 403 additions and 391 deletions
|
@ -109,14 +109,14 @@ struct grub_reiserfs_superblock
|
|||
grub_uint8_t unused[4];
|
||||
grub_uint16_t uuid[8];
|
||||
char label[16];
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_journal_header
|
||||
{
|
||||
grub_uint32_t last_flush_uid;
|
||||
grub_uint32_t unflushed_offset;
|
||||
grub_uint32_t mount_id;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_description_block
|
||||
{
|
||||
|
@ -124,14 +124,14 @@ struct grub_reiserfs_description_block
|
|||
grub_uint32_t len;
|
||||
grub_uint32_t mount_id;
|
||||
grub_uint32_t real_blocks[0];
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_commit_block
|
||||
{
|
||||
grub_uint32_t id;
|
||||
grub_uint32_t len;
|
||||
grub_uint32_t real_blocks[0];
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_stat_item_v1
|
||||
{
|
||||
|
@ -145,7 +145,7 @@ struct grub_reiserfs_stat_item_v1
|
|||
grub_uint32_t ctime;
|
||||
grub_uint32_t rdev;
|
||||
grub_uint32_t first_direct_byte;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_stat_item_v2
|
||||
{
|
||||
|
@ -160,7 +160,7 @@ struct grub_reiserfs_stat_item_v2
|
|||
grub_uint32_t ctime;
|
||||
grub_uint32_t blocks;
|
||||
grub_uint32_t first_direct_byte;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_key
|
||||
{
|
||||
|
@ -172,13 +172,13 @@ struct grub_reiserfs_key
|
|||
{
|
||||
grub_uint32_t offset;
|
||||
grub_uint32_t type;
|
||||
} v1 __attribute__ ((packed));
|
||||
} GRUB_PACKED v1;
|
||||
struct
|
||||
{
|
||||
grub_uint64_t offset_type;
|
||||
} v2 __attribute__ ((packed));
|
||||
} GRUB_PACKED v2;
|
||||
} u;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_item_header
|
||||
{
|
||||
|
@ -187,11 +187,11 @@ struct grub_reiserfs_item_header
|
|||
{
|
||||
grub_uint16_t free_space;
|
||||
grub_uint16_t entry_count;
|
||||
} u __attribute__ ((packed));
|
||||
} GRUB_PACKED u;
|
||||
grub_uint16_t item_size;
|
||||
grub_uint16_t item_location;
|
||||
grub_uint16_t version;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_block_header
|
||||
{
|
||||
|
@ -200,14 +200,14 @@ struct grub_reiserfs_block_header
|
|||
grub_uint16_t free_space;
|
||||
grub_uint16_t reserved;
|
||||
struct grub_reiserfs_key block_right_delimiting_key;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_disk_child
|
||||
{
|
||||
grub_uint32_t block_number;
|
||||
grub_uint16_t size;
|
||||
grub_uint16_t reserved;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_reiserfs_directory_header
|
||||
{
|
||||
|
@ -216,7 +216,7 @@ struct grub_reiserfs_directory_header
|
|||
grub_uint32_t object_id;
|
||||
grub_uint16_t location;
|
||||
grub_uint16_t state;
|
||||
} __attribute__ ((packed));
|
||||
} GRUB_PACKED;
|
||||
|
||||
struct grub_fshelp_node
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue