diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2017-09-06 19:00:04 -0400 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2017-09-06 19:00:04 -0400 |
commit | 9c7e8629876fb3ff115902e37fe562641ce9de11 (patch) | |
tree | 08ca2e4206ccc0dbda2ee946d907763ae9166aab /libgpsd_core.c | |
parent | db56959e1cf2670edb02f27f25580bb4272e9df2 (diff) | |
download | gpsd-9c7e8629876fb3ff115902e37fe562641ce9de11.tar.gz |
Clean up C and Python code-checker warnings.
Diffstat (limited to 'libgpsd_core.c')
-rw-r--r-- | libgpsd_core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libgpsd_core.c b/libgpsd_core.c index ddb22a6d..77992f35 100644 --- a/libgpsd_core.c +++ b/libgpsd_core.c @@ -230,7 +230,6 @@ static void gpsd_run_device_hook(struct gpsd_errout_t *errout, char *device_name, char *hook) { struct stat statbuf; - char buf[HOOK_CMD_MAX]; if (stat(DEVICEHOOKPATH, &statbuf) == -1) gpsd_log(errout, LOG_PROG, @@ -238,6 +237,7 @@ static void gpsd_run_device_hook(struct gpsd_errout_t *errout, DEVICEHOOKPATH, hook); else { int status; + char buf[HOOK_CMD_MAX]; (void)snprintf(buf, sizeof(buf), "%s %s %s", DEVICEHOOKPATH, device_name, hook); gpsd_log(errout, LOG_INF, "running %s\n", buf); |