summaryrefslogtreecommitdiff
path: root/gpsd.c
diff options
context:
space:
mode:
authorChris Kuethe <chris.kuethe@gmail.com>2006-08-18 17:25:23 +0000
committerChris Kuethe <chris.kuethe@gmail.com>2006-08-18 17:25:23 +0000
commit3f97b80784e151405de359b7e561bd4540457531 (patch)
treed925a43117ebe4dfef455871e41f0f875c66e30d /gpsd.c
parent2bf1a6cd107419f99c93652e28e166ba20632134 (diff)
downloadgpsd-3f97b80784e151405de359b7e561bd4540457531.tar.gz
strchr returns char *, so test it against NULL (a pointer) not 0 (an integer)
Diffstat (limited to 'gpsd.c')
-rw-r--r--gpsd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gpsd.c b/gpsd.c
index a66eb0bc..7f2bf0ec 100644
--- a/gpsd.c
+++ b/gpsd.c
@@ -1166,7 +1166,7 @@ static void handle_control(int sfd, char *buf)
} else if (buf[0] == '!') {
p = snarfline(buf+1, &stash);
eq = strchr(stash, '=');
- if (!eq) {
+ if (eq == NULL) {
gpsd_report(1,"<= control(%d): ill-formed command \n", sfd);
(void)write(sfd, "ERROR\n", 3);
} else {