From b0611bc6c36ea258addb6a07a464f5867bc489a7 Mon Sep 17 00:00:00 2001 From: Martin Babinsky Date: Wed, 28 Jan 2015 16:27:19 +0100 Subject: ipa-pwd-extop: added an informational comment about intentional fallthrough This patch is related to this defect reported by covscan in FreeIPA code: """ Error: MISSING_BREAK (CWE-484): /daemons/ipa-slapi-plugins/ipa-pwd-extop/prepost.c:631: unterminated_case: The case for value "2" is not terminated by a 'break' statement. /daemons/ipa-slapi-plugins/ipa-pwd-extop/prepost.c:638: fallthrough: The above case falls through to this one. """ Added a comment informing about intentional falltrough in this place, so that future generations reading the code don't get confused. The patch is the part of a series related to https://fedorahosted.org/freeipa/ticket/4795 Reviewed-By: Alexander Bokovoy --- daemons/ipa-slapi-plugins/ipa-pwd-extop/prepost.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'daemons/ipa-slapi-plugins') diff --git a/daemons/ipa-slapi-plugins/ipa-pwd-extop/prepost.c b/daemons/ipa-slapi-plugins/ipa-pwd-extop/prepost.c index 84eff1701..1c6838052 100644 --- a/daemons/ipa-slapi-plugins/ipa-pwd-extop/prepost.c +++ b/daemons/ipa-slapi-plugins/ipa-pwd-extop/prepost.c @@ -635,6 +635,8 @@ static int ipapwd_pre_mod(Slapi_PBlock *pb) is_smb = 0; is_ipant = 0; + /* After examining the output of covscan, we think that this + * fallthrough is intentional.*/ case LDAP_MOD_ADD: if (!lmod->mod_bvalues || !lmod->mod_bvalues[0]) { -- cgit