summaryrefslogtreecommitdiff
path: root/gpsdclient.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2012-04-21 00:42:16 -0400
committerEric S. Raymond <esr@thyrsus.com>2012-04-21 00:42:16 -0400
commit801f77a86301e16a822da29f7a327a355e376409 (patch)
tree6a00d7ffe6d2b5ad21444f8cede4c778d6da0a81 /gpsdclient.c
parentd679a3257de346d129fcf76f6ee7aea68a622fe6 (diff)
downloadgpsd-801f77a86301e16a822da29f7a327a355e376409.tar.gz
Attempt to head off a compiler warning.
Diffstat (limited to 'gpsdclient.c')
-rw-r--r--gpsdclient.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gpsdclient.c b/gpsdclient.c
index 1e3a96a8..561e8bd6 100644
--- a/gpsdclient.c
+++ b/gpsdclient.c
@@ -137,8 +137,9 @@ enum unit gpsd_units(void)
void gpsd_source_spec(const char *arg, struct fixsource_t *source)
/* standard parsing of a GPS data source spec */
{
- source->server = "localhost";
- source->port = DEFAULT_GPSD_PORT;
+ /* the casts attempt to head off a -Wwrite-strings warning */
+ source->server = (char *)"localhost";
+ source->port = (char *)DEFAULT_GPSD_PORT;
source->device = NULL;
/*@-usedef@ Sigh, splint is buggy */