summaryrefslogtreecommitdiff
path: root/bits.h
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2016-08-15 17:29:38 -0700
committerGary E. Miller <gem@rellim.com>2016-08-15 17:29:38 -0700
commit51500bbd427387bb1847f6d00364091f2bc4f455 (patch)
treeec4d3526ac189f466c31cafe290e1311774eae80 /bits.h
parente67e4118a0cbb5b5cecc62e7440299d0b5b35a37 (diff)
downloadgpsd-51500bbd427387bb1847f6d00364091f2bc4f455.tar.gz
uint was rmoved in C99. If gpsd enforce C99, then uint must go.
uint is now unsigned int.
Diffstat (limited to 'bits.h')
-rw-r--r--bits.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/bits.h b/bits.h
index 8b79c56e..c8f88488 100644
--- a/bits.h
+++ b/bits.h
@@ -35,8 +35,8 @@
extern float getlef32(const char *, int);
extern double getled64(const char *, int);
-#define putle16(buf, off, w) do {putbyte(buf, (off)+1, (uint)(w) >> 8); putbyte(buf, (off), (w));} while (0)
-#define putle32(buf, off, l) do {putle16(buf, (off)+2, (uint)(l) >> 16); putle16(buf, (off), (l));} while (0)
+#define putle16(buf, off, w) do {putbyte(buf, (off)+1, (unsigned int)(w) >> 8); putbyte(buf, (off), (w));} while (0)
+#define putle32(buf, off, l) do {putle16(buf, (off)+2, (unsigned int)(l) >> 16); putle16(buf, (off), (l));} while (0)
/* big-endian access */
#define getbes16(buf, off) ((int16_t)(((uint16_t)getub(buf, (off)) << 8) | (uint16_t)getub(buf, (off)+1)))