[DragonFlyBSD - Bug #3024] sys/dev/netif/wi/if_wi.c:1090]: (style) Redundant condition

sigttou bugtracker-admin at leaf.dragonflybsd.org
Wed Oct 7 22:30:47 PDT 2026


Issue #3024 has been updated by sigttou.


swildner's commit d314b0e9c46 already removes the redundant condition
reported here. In the master, the expressionis !params || (params->ibp_flags & IEEE80211_BPF_CRYPTO), preserving the
NULL check without the redundant second params test. Could this ticket be closed as fixed by d314b0e9c46?

----------------------------------------
Bug #3024: sys/dev/netif/wi/if_wi.c:1090]: (style) Redundant condition
http://bugs.dragonflybsd.org/issues/3024#change-14817

* Author: dcb
* Status: New
* Priority: Low
* Target version: 6.4
* Start date: 2017-04-11
----------------------------------------
sys/dev/netif/wi/if_wi.c:1090]: (style) Redundant condition: params. '!params || (params && params.ibp_flags&IEEE80211_BPF_CRYPTO)' is equivalent to '!params || params.ibp_flags&IEEE80211_BPF_CRYPTO'

Source code is

    if ((wh->i_fc[1] & IEEE80211_FC1_PROTECTED) &&
        (!params || (params && (params->ibp_flags & IEEE80211_BPF_CRYPTO)))) {



-- 
You have received this notification because you have either subscribed to it, or are involved in it.
To change your notification preferences, please click here: http://bugs.dragonflybsd.org/my/account


More information about the Bugs mailing list