Re: [Patch] cld: pad protocol structures

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/25/2009 08:37 PM, Pete Zaitcev wrote:
As it turned out, sizeof produces different results on 64-bit and
32-bit hosts because the size of the structure may aligned on whatever
biggest alignment the gcc decides appropriate. It's not necesserily
the biggest type, as on RISCs and Itanium, where accessing arrays
of structs with misaligned sizeof will cause SIGBUS. As a result,
our structs varied in size despite using fixed-size types.

Our preferred fix is to pad structures so that they become more
portable.

This patch creates a flag day on 32-bit systems (but not on 64-bit
ones). CLD clients and the daemon must be rebuilt.

Signed-Off-By: Pete Zaitcev<zaitcev@xxxxxxxxxx>

applied


--
To unsubscribe from this list: send the line "unsubscribe hail-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Fedora Clound]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux