Corrected bitfields -- the smallest datatype required for each bitfield is now used, rather than relying on GCC to truncate unused bytes in bitfields (thanks to Walt Sacuta).

This commit is contained in:
Dean Camera 2009-03-26 03:22:02 +00:00
parent 1c9092a8a6
commit ca641bba83
4 changed files with 41 additions and 41 deletions

View file

@ -109,16 +109,16 @@
*/
typedef struct
{
unsigned int ReponseCode : 7;
unsigned int Valid : 1;
unsigned char ReponseCode : 7;
unsigned char Valid : 1;
uint8_t SegmentNumber;
unsigned int SenseKey : 4;
unsigned int _RESERVED1 : 1;
unsigned int ILI : 1;
unsigned int EOM : 1;
unsigned int FileMark : 1;
unsigned char SenseKey : 4;
unsigned char _RESERVED1 : 1;
unsigned char ILI : 1;
unsigned char EOM : 1;
unsigned char FileMark : 1;
uint8_t Information[4];
uint8_t AdditionalLength;