summaryrefslogtreecommitdiff
path: root/sirfmon.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2005-05-27 04:33:08 +0000
committerEric S. Raymond <esr@thyrsus.com>2005-05-27 04:33:08 +0000
commit8121f615217a13725f34da97062b16a022271ec8 (patch)
tree0ad5c5cff73683b3011303cc59d11957150dbc05 /sirfmon.c
parenta3d0a3444863bebe63c87111194ad4d95dda2753 (diff)
downloadgpsd-8121f615217a13725f34da97062b16a022271ec8.tar.gz
Get rid of more sprintfs.
Diffstat (limited to 'sirfmon.c')
-rw-r--r--sirfmon.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sirfmon.c b/sirfmon.c
index 5d262e67..263fecd3 100644
--- a/sirfmon.c
+++ b/sirfmon.c
@@ -860,7 +860,7 @@ static void command(char *buf, int len, const char *fmt, ... )
int n;
va_start(ap, fmt) ;
- vsnprintf(buf, sizeof(buf), fmt, ap);
+ (void)vsnprintf(buf, sizeof(buf), fmt, ap);
va_end(ap);
(void)write(devicefd, buf, strlen(buf));
@@ -1065,7 +1065,7 @@ int main (int argc, char **argv)
wattrset(mid27win, A_NORMAL);
wattrset(cmdwin, A_BOLD);
- if (serial)
+ if (serial!=0)
display(cmdwin, 1, 0, "%s %4d N %d", device, bps, stopbits);
else
display(cmdwin, 1, 0, "%s:%s:%s", server, port, device);
@@ -1126,7 +1126,7 @@ int main (int argc, char **argv)
if ((p = strchr(line,'\r')) != NULL)
*p = '\0';
- if (!line[0])
+ if (line[0] == '\0')
continue;
p = line;