Skip to content

Commit

Permalink
ctrl: Allow command line arguments to override config file options.
Browse files Browse the repository at this point in the history
Closes #2010. Thanks to Willem Eradus.
  • Loading branch information
ralight committed Jan 15, 2021
1 parent 300dc54 commit 26fbd0e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 3 additions & 0 deletions ChangeLog.txt
Expand Up @@ -7,6 +7,9 @@ Broker:
- Add notes that libsystemd-dev or similar is needed if building with systemd
support. Closes #2019.

Apps:
- Allow command line arguments to override config file options in
mosquitto_ctrl. Closes #2010.

2.0.5 - 2021-01-11
==================
Expand Down
6 changes: 3 additions & 3 deletions apps/mosquitto_ctrl/options.c
Expand Up @@ -89,11 +89,11 @@ int ctrl_config_parse(struct mosq_config *cfg, int *argc, char **argv[])

init_config(cfg);

/* Deal with real argc/argv */
rc = client_config_line_proc(cfg, argc, argv);
rc = client_config_load(cfg);
if(rc) return rc;

rc = client_config_load(cfg);
/* Deal with real argc/argv */
rc = client_config_line_proc(cfg, argc, argv);
if(rc) return rc;

#ifdef WITH_TLS
Expand Down

0 comments on commit 26fbd0e

Please sign in to comment.