summaryrefslogtreecommitdiff
path: root/gpsdclient.c
diff options
context:
space:
mode:
authorRob Norris <rw_norris@hotmail.com>2016-02-23 01:05:32 +0000
committerEric S. Raymond <esr@thyrsus.com>2016-02-23 17:33:34 -0500
commit01f89a8f786f6bc9588f257e77d38ea871a2d53c (patch)
tree300977b87bbf1237b23fcca26380b956cb262faa /gpsdclient.c
parent40c9a8703efd8850dc3fed44ad9cc91d37d03343 (diff)
downloadgpsd-01f89a8f786f6bc9588f257e77d38ea871a2d53c.tar.gz
Fix small memory leak in gpsd client programs.
Allocation is otherwise never freed and is in fact unnecessary.
Diffstat (limited to 'gpsdclient.c')
-rw-r--r--gpsdclient.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gpsdclient.c b/gpsdclient.c
index c3b24451..2ab7ff6a 100644
--- a/gpsdclient.c
+++ b/gpsdclient.c
@@ -144,7 +144,7 @@ void gpsd_source_spec(const char *arg, struct fixsource_t *source)
if (arg != NULL) {
char *colon1, *skipto, *rbrk;
- source->spec = strdup(arg);
+ source->spec = (char *)arg;
assert(source->spec != NULL);
skipto = source->spec;