diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-09-12 11:27:58 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-09-12 11:27:58 +0000 |
commit | 0c564ddd977451d93d5cf6898a66ebd608e32862 (patch) | |
tree | 76546fbda8fdc9ae0924f8bc8717793906e72f55 /src/options.c | |
parent | Releasing debian version 2.0.3-1. (diff) | |
download | dnscap-0c564ddd977451d93d5cf6898a66ebd608e32862.tar.xz dnscap-0c564ddd977451d93d5cf6898a66ebd608e32862.zip |
Merging upstream version 2.1.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/options.c')
-rw-r--r-- | src/options.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/options.c b/src/options.c index 29a5dad..8d03c26 100644 --- a/src/options.c +++ b/src/options.c @@ -228,6 +228,13 @@ int option_parse(options_t* options, const char* option) options->bpf_hosts_apply_all = 1; return 0; } + } else if (have("pid_file")) { + if (options->pid_file) { + free(options->pid_file); + } + if ((options->pid_file = strdup(argument))) { + return 0; + } } return 1; @@ -244,5 +251,9 @@ void options_free(options_t* options) free(options->group); options->group = 0; } + if (options->pid_file) { + free(options->pid_file); + options->pid_file = 0; + } } } |