实现struct字节不对齐的办法
时间:2006-05-18 来源:b46
今天从网上偶然发现关于实现struct字节不对齐的讨论,以前没注意过,记下来供参考学习。
struct A{
unsigned char a;
unsigned int b;
} __attribute__((packed));
unsigned char a;
unsigned int b;
} __attribute__((packed));
相关阅读 更多 +
时间:2006-05-18 来源:b46