diff options
author | Fred Wright <fw@fwright.net> | 2017-02-20 20:12:44 -0800 |
---|---|---|
committer | Fred Wright <fw@fwright.net> | 2017-02-20 20:12:44 -0800 |
commit | 6d649db5134567fb4e3bd83b92d85a69aecd5938 (patch) | |
tree | 3b1d144dbcc70533d78c53a0ae12cbabc146f4e6 | |
parent | 602e64f2e55b4e4442a88e136a8749dd4d309017 (diff) | |
download | gpsd-6d649db5134567fb4e3bd83b92d85a69aecd5938.tar.gz |
Whitespace cleanups related to recent changes.
-rw-r--r-- | gps2udp.c | 5 | ||||
-rw-r--r-- | gpspipe.c | 3 | ||||
-rw-r--r-- | lcdgps.c | 2 | ||||
-rw-r--r-- | libgps_core.c | 4 | ||||
-rw-r--r-- | ntpshmmon.c | 11 |
5 files changed, 17 insertions, 8 deletions
@@ -164,7 +164,10 @@ static int open_udp(char **hostport) remote[channel].sin_family = (sa_family_t)AF_INET; hp = gethostbyname(hostname); if (hp==NULL) { - (void)fprintf(stderr, "gps2udp: syntax is [-u hostname:port] [%s] is not a valid hostname\n",hostname); + (void)fprintf(stderr, + "gps2udp: syntax is [-u hostname:port] [%s]" + " is not a valid hostname\n", + hostname); return (-1); } @@ -371,7 +371,8 @@ int main(int argc, char **argv) if (serialport != NULL) { if (write(fd_out, serbuf, (size_t) j) == -1) { (void)fprintf(stderr, - "gpspipe: serial port write error, %s(%d)\n", + "gpspipe: serial port write error," + " %s(%d)\n", strerror(errno), errno); exit(EXIT_FAILURE); } @@ -405,7 +405,7 @@ int main(int argc, char *argv[]) for (;;) { /* heart of the client */ if (!gps_waiting(&gpsdata, 50000000)) { - (void)fprintf( stderr, "lcdgps: error while waiting\n"); + (void)fprintf(stderr, "lcdgps: error while waiting\n"); exit(EXIT_FAILURE); } else { (void)gps_read(&gpsdata); diff --git a/libgps_core.c b/libgps_core.c index 54eb8c78..7df1c9a3 100644 --- a/libgps_core.c +++ b/libgps_core.c @@ -102,7 +102,9 @@ int gps_open(const char *host, #endif /* SOCKET_EXPORT_ENABLE */ #ifndef USES_HOST - (void)fprintf(stderr, "No methods available for connnecting to %s!\n", host); + (void)fprintf(stderr, + "No methods available for connnecting to %s!\n", + host); #endif /* USES_HOST */ #undef USES_HOST diff --git a/ntpshmmon.c b/ntpshmmon.c index 04cd8c6e..1fa0ac88 100644 --- a/ntpshmmon.c +++ b/ntpshmmon.c @@ -57,7 +57,8 @@ int main(int argc, char **argv) argv[0], VERSION, REVISION); exit(EXIT_SUCCESS); case 'h': - (void)fprintf(stderr, + (void)fprintf( + stderr, "usage: ntpshmmon [-s] [-n max] [-t timeout] [-v] [-h] [-V]\n" " -h print this help\n" " -n nsamples exit after nsamples\n" @@ -77,7 +78,7 @@ int main(int argc, char **argv) for (i = 0; i < NTPSEGMENTS; i++) { segments[i] = shm_get(i, false, true); if (verbose && segments[i] != NULL) - (void)fprintf(stderr, "unit %d opened\n", i); + (void)fprintf(stderr, "unit %d opened\n", i); } if (killall) { @@ -144,14 +145,16 @@ int main(int argc, char **argv) /* do nothing, data not ready, wait another cycle */ break; case BAD_MODE: - (void)fprintf(stderr, "ntpshmmon: unknown mode %d on segment %s\n", + (void)fprintf(stderr, + "ntpshmmon: unknown mode %d on segment %s\n", shm_stat.status, ntp_name(i)); break; case CLASH: /* do nothing, data is corrupt, wait another cycle */ break; default: - (void)fprintf(stderr, "ntpshmmon: unknown status %d on segment %s\n", + (void)fprintf(stderr, + "ntpshmmon: unknown status %d on segment %s\n", status, ntp_name(i)); break; } |