From: Volker Lendecke Date: Thu, 16 Oct 2025 11:07:23 +0000 (+0200) Subject: auth: Simplify check_account() X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5a4ca24842fcddc3e46e7491e976e56c1210cf80;p=thirdparty%2Fsamba.git auth: Simplify check_account() We have strlower_talloc() for this Signed-off-by: Volker Lendecke Reviewed-by: Anoop C S --- diff --git a/source3/auth/auth_util.c b/source3/auth/auth_util.c index b7a81f09c9e..4ee158e0255 100644 --- a/source3/auth/auth_util.c +++ b/source3/auth/auth_util.c @@ -1883,13 +1883,10 @@ static NTSTATUS check_account(TALLOC_CTX *mem_ctx, const char *domain, char *real_username = NULL; struct passwd *passwd; - lower_username = talloc_strdup(mem_ctx, username); + lower_username = strlower_talloc(mem_ctx, username); if (!lower_username) { return NT_STATUS_NO_MEMORY; } - if (!strlower_m( lower_username )) { - return NT_STATUS_INVALID_PARAMETER; - } orig_dom_user = talloc_asprintf(mem_ctx, "%s%c%s",