libcli/smb: add FLAG_CASELESS_PATHNAMES based on FILE_CASE_SENSITIVE_SEARCH to smb1...
authorStefan Metzmacher <metze@samba.org>
Fri, 27 Sep 2013 03:31:07 +0000 (05:31 +0200)
committerMichael Adam <obnox@samba.org>
Thu, 17 Oct 2013 14:09:10 +0000 (16:09 +0200)
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
libcli/smb/smbXcli_base.c

index a2a559af96ccc7a1df1abec60c14776c1345efab..082b62604b1f49bf1a4e5dff89ab75503000feb0 100644 (file)
@@ -1273,6 +1273,13 @@ struct tevent_req *smb1cli_req_create(TALLOC_CTX *mem_ctx,
        if (tcon) {
                tid = tcon->smb1.tcon_id;
 
+               if (tcon->fs_attributes & FILE_CASE_SENSITIVE_SEARCH) {
+                       clear_flags |= FLAG_CASELESS_PATHNAMES;
+               } else {
+                       /* Default setting, case insensitive. */
+                       additional_flags |= FLAG_CASELESS_PATHNAMES;
+               }
+
                if (smbXcli_conn_dfs_supported(conn) &&
                    smbXcli_tcon_is_dfs_share(tcon))
                {