From 37a517eb8ac23b8aa3aa0abce82aee0977354334 Mon Sep 17 00:00:00 2001 From: Vadim Vetrov Date: Mon, 14 Oct 2024 01:16:46 +0300 Subject: [PATCH] Fix #155 synfake option deleted but present in openwrt --- args.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/args.c b/args.c index 7f01001..5fd0fb2 100644 --- a/args.c +++ b/args.c @@ -426,6 +426,23 @@ int parse_args(int argc, char *argv[]) { goto invalid_opt; } + break; + case OPT_SYNFAKE: + if (strcmp(optarg, "1") == 0) { + sect_config->synfake = 1; + } else if (strcmp(optarg, "0") == 0) { + sect_config->synfake = 0; + } else { + goto invalid_opt; + } + + break; + case OPT_SYNFAKE_LEN: + num = parse_numeric_option(optarg); + if (errno != 0 || num < 0) { + goto invalid_opt; + } + sect_config->synfake_len = num; break; default: goto error;