summaryrefslogtreecommitdiff
path: root/driver_superstar2.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2009-09-10 09:05:32 +0000
committerEric S. Raymond <esr@thyrsus.com>2009-09-10 09:05:32 +0000
commitb85ca4e26b61471cd17e9468efbb49c56b77fdb9 (patch)
tree51fe0e01ae5665a98f4b28fda241ee244ca80e8e /driver_superstar2.c
parentdad8b2b68113840c826e43e3857c487498271c85 (diff)
downloadgpsd-b85ca4e26b61471cd17e9468efbb49c56b77fdb9.tar.gz
Son of the Splint Cleanup.
Major change in this set is enforcong consistency about the data type of serial parity information.
Diffstat (limited to 'driver_superstar2.c')
-rw-r--r--driver_superstar2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/driver_superstar2.c b/driver_superstar2.c
index 37a4e916..c4bfb9c0 100644
--- a/driver_superstar2.c
+++ b/driver_superstar2.c
@@ -421,7 +421,7 @@ superstar2_write(struct gps_device_t *session, char *msg, size_t msglen)
unsigned short c = 0;
ssize_t i;
- for (i = 0; i < msglen - 2; i++)
+ for (i = 0; i < (ssize_t)(msglen - 2); i++)
c += (unsigned short)msg[i];
c += 0x100;
// c = htons(c); // XXX is this needed on big-endian machines?
@@ -594,7 +594,7 @@ static bool superstar2_set_speed(struct gps_device_t *session,
speed_t speed, char parity, int stopbits)
{
/* parity and stopbit switching aren't available on this chip */
- if (parity!=(char)session->gpsdata.dev.parity || stopbits!=(int)session->gpsdata.dev.stopbits) {
+ if (parity!=session->gpsdata.dev.parity || stopbits!=(int)session->gpsdata.dev.stopbits) {
return false;
} else {
/*@ +charint @*/