summaryrefslogtreecommitdiff
path: root/bits.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2012-04-20 13:15:43 -0400
committerEric S. Raymond <esr@thyrsus.com>2012-04-20 13:15:43 -0400
commit464b4d3e4a4ec77cecf0e6f8fa818b76fb949146 (patch)
treec7c630cfddeee42aea4006543ab1f58484130463 /bits.c
parent156c9fb299e44c691e0bc972408a59b813b63bd9 (diff)
downloadgpsd-464b4d3e4a4ec77cecf0e6f8fa818b76fb949146.tar.gz
Suppress compiler warnings and do splint cleanup. All regression tests pass.
Diffstat (limited to 'bits.c')
-rw-r--r--bits.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bits.c b/bits.c
index 34fd4064..502e0a7d 100644
--- a/bits.c
+++ b/bits.c
@@ -27,13 +27,13 @@ uint64_t ubits(char buf[], unsigned int start, unsigned int width, bool le)
/*@i1@*/ assert(width <= sizeof(uint64_t) * CHAR_BIT);
for (i = start / CHAR_BIT;
i < (start + width + CHAR_BIT - 1) / CHAR_BIT; i++) {
- fld <<= CHAR_BIT;
+ /*@i1@*/fld <<= CHAR_BIT;
fld |= (unsigned char)buf[i];
}
end = (start + width) % CHAR_BIT;
if (end != 0) {
- fld >>= (CHAR_BIT - end);
+ /*@i1@*/fld >>= (CHAR_BIT - end);
}
/*@ -shiftimplementation @*/