On Wed, 12/03 22:28, Bryan D. Payne wrote: > > > > It is critical as a transport data structure. You have to define a > > byte-by-byte > > layout (concerning endianness and padding) and use padding fields together > > with > > QEMU_PACKED, so the representation is not dependent on alignment > > > This makes sense for network protocols. But, in this case, the protocol is > always taking placing over a unix socket on the localhost. This is why I > wasn't sure that it was necessary. > > Just to be clear... the QMP connection could go over the network, but its > only purpose is to set up the unix socket on the local machine (meaning > that doing it over the network is kind of pointless, even if it is > possible). Once the unix socket is setup, the memory access protocol > happens over that socket.
This doesn't stop the client from using a different alignment than we expect. It's necessary to be explicit as a binary protocol. Fam