Allon Mureinik has uploaded a new change for review. Change subject: core: GSSAPIDirContextAuthentication null-check ......................................................................
core: GSSAPIDirContextAuthentication null-check Removed a redundant null check on the "result" variable, since a couple of lines before hand, result.getAuditLogType() was called. Hence, result is clearly not null. Change-Id: Ideb107acdbbe55e8efd4bb90f6ff4ce0be168746 Signed-off-by: Allon Mureinik <amure...@redhat.com> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/adbroker/GSSAPIDirContextAuthenticationStrategy.java 1 file changed, 4 insertions(+), 5 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/30/12330/1 diff --git a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/adbroker/GSSAPIDirContextAuthenticationStrategy.java b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/adbroker/GSSAPIDirContextAuthenticationStrategy.java index 30a82c6..70dbb47 100644 --- a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/adbroker/GSSAPIDirContextAuthenticationStrategy.java +++ b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/adbroker/GSSAPIDirContextAuthenticationStrategy.java @@ -15,14 +15,13 @@ import javax.security.auth.login.LoginContext; import javax.security.auth.login.LoginException; -import org.springframework.ldap.core.support.DirContextAuthenticationStrategy; - import org.ovirt.engine.core.common.config.Config; import org.ovirt.engine.core.common.config.ConfigValues; -import org.ovirt.engine.core.utils.log.Log; -import org.ovirt.engine.core.utils.log.LogFactory; import org.ovirt.engine.core.utils.kerberos.AuthenticationResult; import org.ovirt.engine.core.utils.kerberos.KerberosReturnCodeParser; +import org.ovirt.engine.core.utils.log.Log; +import org.ovirt.engine.core.utils.log.LogFactory; +import org.springframework.ldap.core.support.DirContextAuthenticationStrategy; /** * @@ -142,7 +141,7 @@ if (result.getAuditLogType() != null) { LdapBrokerUtils.logEventForUser(userName, result.getAuditLogType()); } - if (result == AuthenticationResult.OTHER || result == null) { + if (result == AuthenticationResult.OTHER) { // An error our error parser does not recognize log.error("Error from Kerberos: " + ex.getMessage()); } else { -- To view, visit http://gerrit.ovirt.org/12330 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ideb107acdbbe55e8efd4bb90f6ff4ce0be168746 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Allon Mureinik <amure...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches