diff options
author | Artjoms Rimdjonoks <artjoms.rimdjonoks@zabbix.com> | 2022-05-01 23:24:47 +0300 |
---|---|---|
committer | Artjoms Rimdjonoks <artjoms.rimdjonoks@zabbix.com> | 2022-05-01 23:24:47 +0300 |
commit | b7795a7ad4a604d534eeacfd08d3ebbb9d4252cc (patch) | |
tree | a84cf8a6dc4bf28e40f64380b297ea3e78b1ad60 /src/zabbix_agent/zabbix_agentd.c | |
parent | 23d1989d1a0f297013c7ecee21aa76fa34090401 (diff) |
.......... [DEV-2113] added additional fixes
Diffstat (limited to 'src/zabbix_agent/zabbix_agentd.c')
-rw-r--r-- | src/zabbix_agent/zabbix_agentd.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/zabbix_agent/zabbix_agentd.c b/src/zabbix_agent/zabbix_agentd.c index 93f8d7d2ca0..9a6940074cd 100644 --- a/src/zabbix_agent/zabbix_agentd.c +++ b/src/zabbix_agent/zabbix_agentd.c @@ -341,10 +341,13 @@ static int parse_commandline(int argc, char **argv, ZBX_TASK_EX *t) #endif unsigned short opt_count[256] = {0}; + char *zbx_optarg = NULL; + int zbx_optind = 0; + t->task = ZBX_TASK_START; /* parse the command-line */ - while ((char)EOF != (ch = (char)zbx_getopt_long(argc, argv, shortopts, longopts, NULL))) + while ((char)EOF != (ch = (char)zbx_getopt_long(argc, argv, shortopts, longopts, NULL, &zbx_optarg, &zbx_optind))) { opt_count[(unsigned char)ch]++; |