Paddding thing once more
Jakub Piotr Cłapa
jpc at pld-linux.org
Mon Aug 8 23:45:17 EST 2005
Sorry for so many questions about boring things but I hope you excuse
three more.
1. The padding for every value is basically a constraint on it's start
address (counting from the beginning of the header or body) which must
be a multiple of the alignment value.
Example:
When we marshal "yyyu" then between "yyy" and "u" there must be one nul
byte (regardless of the endianess the padding is always before the value?)
2. The padding of header is simply adding some nul bytes to the end of
the header to make it's length divisible by 8? It has nothing to do with
header fileds (which are structs) 8-byte padding? (because their padding
always goes before the struct value not after it?)
3. Why? What is gained from using paddings in DBus protocol? (it's
probably a question about binary formats design theory) I found in the
source that this is borrowed from ORBit2 but haven't seen any
explanation why.
--
Regards,
Jakub Piotr Cłapa
More information about the dbus
mailing list