From: Volker Lendecke Date: Tue, 27 Mar 2018 22:03:15 +0000 (-0500) Subject: lsa_server: Fix CID 1433608 Dereference after null check X-Git-Tag: talloc-2.1.13~122 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9ecc6f3b520ea6388a3b8d9f61cd2bbf16452400;p=thirdparty%2Fsamba.git lsa_server: Fix CID 1433608 Dereference after null check Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- diff --git a/source4/rpc_server/lsa/lsa_lookup.c b/source4/rpc_server/lsa/lsa_lookup.c index 3baff1ec11f..becbcfc8b64 100644 --- a/source4/rpc_server/lsa/lsa_lookup.c +++ b/source4/rpc_server/lsa/lsa_lookup.c @@ -88,7 +88,7 @@ static NTSTATUS dcesrv_lsa_lookup_name(struct lsa_policy_state *state, bool match = false; int ret; - if (principal == NULL && principal[0] == '\0') { + if ((principal == NULL) || (principal[0] == '\0')) { return NT_STATUS_NONE_MAPPED; }