diff options
author | Pierre Lebleu <pme.lebleu@gmail.com> | 2017-05-04 10:50:56 +0200 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2017-05-09 23:54:15 +0200 |
commit | 6039c7f4b0052c4da21520cdd604f04a5a67f50d (patch) | |
tree | 3a4c8d563950f53a6f4b51f5ef63a2483f3642ff /defaults.c | |
parent | c328d1f6fe982888b5f5852423ee0a41cee3adb1 (diff) | |
download | firewall3-6039c7f4b0052c4da21520cdd604f04a5a67f50d.tar.gz |
firewall3: check the return value of fw3_parse_options()
The return value of fw3_parse_options() should be checked.
Signed-off-by: Pierre Lebleu <pme.lebleu@gmail.com>
Diffstat (limited to 'defaults.c')
-rw-r--r-- | defaults.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -107,7 +107,8 @@ fw3_load_defaults(struct fw3_state *state, struct uci_package *p) continue; } - fw3_parse_options(&state->defaults, fw3_flag_opts, s); + if(!fw3_parse_options(&state->defaults, fw3_flag_opts, s)) + warn_elem(e, "has invalid options"); check_policy(e, &defs->policy_input, "input"); check_policy(e, &defs->policy_output, "output"); |