- Is there portable unsigned long in C++?
- Is there a way to make a portable structures?
On my home machine unsigned long is 8 bytes. On work machine its 4 bytes.
When you start at home applications that are written on work there is a problem of correctness of data transmitted over the network.
Thanks.
#include <stdint.h>for the following typedefs:(u)int8_t(u)int16_t(u)int32_t(u)int64_tWhile the last may or may not be available, depending on the platform.