From: Alex Dewar Date: Fri, 28 Aug 2020 13:55:23 +0000 (+0100) Subject: netlabel: remove unused param from audit_log_format() X-Git-Tag: howlett/maple_spf/20210104~792^2~418 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=0f091e43310f5c292b7094f9f115e651358e8053;p=users%2Fjedix%2Flinux-maple.git netlabel: remove unused param from audit_log_format() Commit d3b990b7f327 ("netlabel: fix problems with mapping removal") added a check to return an error if ret_val != 0, before ret_val is later used in a log message. Now it will unconditionally print "... res=1". So just drop the check. Addresses-Coverity: ("Dead code") Fixes: d3b990b7f327 ("netlabel: fix problems with mapping removal") Signed-off-by: Alex Dewar Acked-by: Paul Moore Signed-off-by: David S. Miller --- diff --git a/net/netlabel/netlabel_domainhash.c b/net/netlabel/netlabel_domainhash.c index d07de2c0fbc7..38aaeadec13d 100644 --- a/net/netlabel/netlabel_domainhash.c +++ b/net/netlabel/netlabel_domainhash.c @@ -600,9 +600,8 @@ int netlbl_domhsh_remove_entry(struct netlbl_dom_map *entry, audit_buf = netlbl_audit_start_common(AUDIT_MAC_MAP_DEL, audit_info); if (audit_buf != NULL) { audit_log_format(audit_buf, - " nlbl_domain=%s res=%u", - entry->domain ? entry->domain : "(default)", - ret_val == 0 ? 1 : 0); + " nlbl_domain=%s res=1", + entry->domain ? entry->domain : "(default)"); audit_log_end(audit_buf); }