[zeromq-dev] portable uint32_t ?

Steven McCoy steven.mccoy at miru.hk
Thu Aug 5 14:47:19 CEST 2010

On 5 August 2010 20:21, Matt Weinstein <mattweinstein at gmail.com> wrote:

> Folks,
> A quick question -- I really want a uint32_t to hold my 0xdeadbeef, is
> there a portable/preferred way to get a 32 bit unsigned value? (( I
> don't like making assumptions about C99 compliance ))
You can find stdint.h on many platforms, and you can already find several
versions for Windows.  Everything else varies due to LP64, LLP64, ILP64,
SILP64, etc.

Alternatives include Glib's guint32, and sometimes you can see u_int32 and

Basically fall back is to define it yourself, i.e. a zmq_uint32_t or
something equally horrific, Apple uses mDNSu32 in mDNSResponder for example.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20100805/a7f81687/attachment.htm>

More information about the zeromq-dev mailing list