diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2015-01-21 18:23:46 -0500 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2015-01-21 18:23:46 -0500 |
commit | ab59cbb7b64909090d64866ebdf43fd27f584c5d (patch) | |
tree | c80d25e389f74cd506a733f8106235693b93f092 /gps2udp.c | |
parent | aeb3bdae85bddab96c749dfc07ecf6d7e0b2fdf2 (diff) | |
download | gpsd-ab59cbb7b64909090d64866ebdf43fd27f584c5d.tar.gz |
Coverity/splint cleanup.
Turned up a bug in where a counter was incremented un the Navcom driver;
this required one test rebuild.
Diffstat (limited to 'gps2udp.c')
-rw-r--r-- | gps2udp.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -90,7 +90,7 @@ static int send_udp (char *nmeastring, size_t ind) if (ind == 0) { /* compute message size and add 0x0a 0x0d */ for (ind=0; nmeastring [ind] != '\0'; ind ++) { - if (ind >= sizeof(message)) { + if (ind >= sizeof(message) - 3) { fprintf(stderr, "gps2udp: too big [%s] \n", nmeastring); return -1; } |