diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2014-12-19 14:00:59 -0800 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2014-12-30 08:07:50 -0800 |
commit | 5d619de4610fa00d0b633e1916c49e59824440ff (patch) | |
tree | f47278e52def825767fbf4a451dae0eb1ec602bf /rt/tst-mqueue1.c | |
parent | 6490d945378090db82be2759ff66719a980d9c1c (diff) | |
download | glibc-5d619de4610fa00d0b633e1916c49e59824440ff.zip glibc-5d619de4610fa00d0b633e1916c49e59824440ff.tar.gz glibc-5d619de4610fa00d0b633e1916c49e59824440ff.tar.bz2 |
Replace %ld/%lu with %jd/%ju and cast to intmax_t/uintmax_t
Diffstat (limited to 'rt/tst-mqueue1.c')
-rw-r--r-- | rt/tst-mqueue1.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/rt/tst-mqueue1.c b/rt/tst-mqueue1.c index c242c37..e310fb3 100644 --- a/rt/tst-mqueue1.c +++ b/rt/tst-mqueue1.c @@ -26,6 +26,7 @@ #include <sys/wait.h> #include <time.h> #include <unistd.h> +#include <stdint.h> #include "tst-mqueue.h" static int @@ -46,20 +47,21 @@ check_attrs (struct mq_attr *attr, int nonblock, long cnt) if (attr->mq_maxmsg != 10 || attr->mq_msgsize != 1) { printf ("attributes don't match those passed to mq_open\n" - "mq_maxmsg %ld, mq_msgsize %ld\n", - attr->mq_maxmsg, attr->mq_msgsize); + "mq_maxmsg %jd, mq_msgsize %jd\n", + (intmax_t) attr->mq_maxmsg, (intmax_t) attr->mq_msgsize); result = 1; } if ((attr->mq_flags & O_NONBLOCK) != nonblock) { - printf ("mq_flags %lx != %x\n", (attr->mq_flags & O_NONBLOCK), nonblock); + printf ("mq_flags %jx != %x\n", + (intmax_t) (attr->mq_flags & O_NONBLOCK), nonblock); result = 1; } if (attr->mq_curmsgs != cnt) { - printf ("mq_curmsgs %ld != %ld\n", attr->mq_curmsgs, cnt); + printf ("mq_curmsgs %jd != %ld\n", (intmax_t) attr->mq_curmsgs, cnt); result = 1; } |