What is the difference between u_int32_t
and uint32_t
?
As others have mentioned, uint32_t is a standard C99 type.
Anyway, the takeaway is that if you're writing portable C code or C header files meant to be shared between different devices/architectures, you can use stdint.h.
uint32_t
is a standard C99 type u_int32_t
is used internally in some POSIX implementations.
The variable type uint32_t is an unsigned 32-bit integer data type defined according to the so-called C99 standard. Not all compilers comply with the standard. And u_int32_t is used for some internally implementations.
uint32_t is standard C99, while u_int32_t is used on certain Unix platforms.