CVSROOT:        /cvs
Module name:    src
Changes by:     aw...@cvs.openbsd.org   2017/06/16 13:59:13

Modified files:
        sbin/pfctl     : pfctl.c 

Log message:
pfctl: merge identifical if conditions and void functions discarding ret values

Transform the following functions (which never return anything other than 0, and
whose return value is never used) to void:

* pfctl_clear_stats, pfctl_clear_interface_flags, pfctl_clear_rules,
pfctl_clear_src_nodes, pfctl_clear_states
* pfctl_kill_src_nodes, pfctl_net_kill_states, pfctl_label_kill_states,
pfctl_id_kill_states, pfctl_key_kill_states

inside main: merge two identical if conditions next to each other into one.

Submitted by rain1 (thanks!) with additional credit to:
- mikeb@ for pointing out we can void all _clear_ functions
- ghostyy for pointing out all _kill_ functions can be voided

OK tb@, mikeb@

Reply via email to