From 6ce29dc9add1252b0ded9d2c1c2b6bae74604cc4 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Tue, 18 Nov 2008 17:03:38 +0100 Subject: Fix trans2findfirst for the large directory optimization With case sensitive = yes preserve case = no short preserve case = no default case = upper a "dir FOO.txt" would not find "FOO.TXT" because FOO.txt ends up unconverted in the mask for mask_match. Jeremy, please check! Volker --- source3/smbd/filename.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source3') diff --git a/source3/smbd/filename.c b/source3/smbd/filename.c index 562f1e8d94..3eb2d63734 100644 --- a/source3/smbd/filename.c +++ b/source3/smbd/filename.c @@ -206,6 +206,11 @@ NTSTATUS unix_convert(TALLOC_CTX *ctx, *pp_saved_last_component = talloc_strdup(ctx, orig_path); } + if (conn->case_sensitive && !conn->case_preserve && + !conn->short_case_preserve) { + strnorm(*pp_saved_last_component, + lp_defaultcase(SNUM(conn))); + } } if (!(name = talloc_strdup(ctx, orig_path))) { -- cgit