|
|
| version 1.2, 2004/01/10 17:24:01 | version 1.3, 2004/01/13 16:24:00 |
|---|---|
| Line 59 typedef struct { | Line 59 typedef struct { |
| // ---- MS-DOSストラクチャー (little endian!) | // ---- MS-DOSストラクチャー (little endian!) |
| #ifndef __GNUC__ | |
| #pragma pack(push, 1) | #pragma pack(push, 1) |
| #define ATTRIBUTE_PACKED | |
| #else | |
| #define ATTRIBUTE_PACKED __attribute__((packed)) | |
| #endif | |
| /* FindFirst/Next data block */ | /* FindFirst/Next data block */ |
| typedef struct { | typedef struct { |
| Line 69 typedef struct { | Line 74 typedef struct { |
| BYTE dir_entry_no[2]; | BYTE dir_entry_no[2]; |
| BYTE dir_sector[2]; | BYTE dir_sector[2]; |
| BYTE f1[4]; | BYTE f1[4]; |
| } _SRCHREC, *SRCHREC; // 21bytes (see int214E) | } ATTRIBUTE_PACKED _SRCHREC, *SRCHREC; // 21bytes (see int214E) |
| /* Directory entry for 'found' file */ | /* Directory entry for 'found' file */ |
| typedef struct { | typedef struct { |
| Line 80 typedef struct { | Line 85 typedef struct { |
| BYTE file_date[2]; | BYTE file_date[2]; |
| BYTE start_sector[2]; | BYTE start_sector[2]; |
| BYTE file_size[4]; | BYTE file_size[4]; |
| } _DIRREC, *DIRREC; | } ATTRIBUTE_PACKED _DIRREC, *DIRREC; |
| /* System File Table entry */ | /* System File Table entry */ |
| typedef struct { | typedef struct { |
| Line 99 typedef struct { | Line 104 typedef struct { |
| BYTE dir_sector[2]; | BYTE dir_sector[2]; |
| UINT8 dir_entry_no; | UINT8 dir_entry_no; |
| BYTE file_name[11]; | BYTE file_name[11]; |
| } _SFTREC, *SFTREC; | } ATTRIBUTE_PACKED _SFTREC, *SFTREC; |
| /* Current Directory Structure */ | /* Current Directory Structure */ |
| typedef struct { | typedef struct { |
| Line 107 typedef struct { | Line 112 typedef struct { |
| BYTE flags[2]; | BYTE flags[2]; |
| BYTE f1[10]; | BYTE f1[10]; |
| BYTE root_ofs[2]; | BYTE root_ofs[2]; |
| } _CDS3, *CDS3; | } ATTRIBUTE_PACKED _CDS3, *CDS3; |
| typedef struct { | typedef struct { |
| char current_path[67]; | char current_path[67]; |
| Line 115 typedef struct { | Line 120 typedef struct { |
| BYTE f1[10]; | BYTE f1[10]; |
| BYTE root_ofs[2]; | BYTE root_ofs[2]; |
| BYTE f2[7]; | BYTE f2[7]; |
| } _CDS4, *CDS4; | } ATTRIBUTE_PACKED _CDS4, *CDS4; |
| /* Swappable DOS Area for DOS3 */ | /* Swappable DOS Area for DOS3 */ |
| typedef struct { | typedef struct { |
| Line 142 typedef struct { | Line 147 typedef struct { |
| BYTE f7[72]; | BYTE f7[72]; |
| _SRCHREC rename_srchrec; | _SRCHREC rename_srchrec; |
| _DIRREC rename_dirrec; | _DIRREC rename_dirrec; |
| } _SDA3, *SDA3; // (see int215D06) | } ATTRIBUTE_PACKED _SDA3, *SDA3; // (see int215D06) |
| /* Swappable DOS Area for DOS4+ */ | /* Swappable DOS Area for DOS4+ */ |
| typedef struct { | typedef struct { |
| Line 173 typedef struct { | Line 178 typedef struct { |
| BYTE f8[29]; | BYTE f8[29]; |
| _SRCHREC rename_srchrec; | _SRCHREC rename_srchrec; |
| _DIRREC rename_dirrec; | _DIRREC rename_dirrec; |
| } _SDA4, *SDA4; // (see int215D06) | } ATTRIBUTE_PACKED _SDA4, *SDA4; // (see int215D06) |
| typedef union { | typedef union { |
| struct { | struct { |
| _SDA3 sda; | _SDA3 sda; |
| _CDS3 cds; | _CDS3 cds; |
| } ver3; | } ATTRIBUTE_PACKED ver3; |
| struct { | struct { |
| _SDA4 sda; | _SDA4 sda; |
| _CDS4 cds; | _CDS4 cds; |
| } ver4; | } ATTRIBUTE_PACKED ver4; |
| } _SDACDS, *SDACDS; | } _SDACDS, *SDACDS; |
| #ifndef __GNUC__ | |
| #pragma pack(pop) | #pragma pack(pop) |
| #else | |
| #undef ATTRIBUTE_PACKED | |
| #endif | |