summaryrefslogtreecommitdiff
path: root/fs/smb/client/smb2pdu.c
diff options
context:
space:
mode:
authorDr. David Alan Gilbert <linux@treblig.org>2023-08-17 01:22:31 +0100
committerSteve French <stfrench@microsoft.com>2023-08-30 08:55:52 -0500
commitde54845290cee3f65dcd03b35a2bd7f2f7aed2ac (patch)
treef37f6f4f395fd1339f2c52881248baf248440c83 /fs/smb/client/smb2pdu.c
parent089f7f591348ca3325639f541fa4f78d9540dab5 (diff)
fs/smb/client: Use common code in client
Now we've got the common code, use it for the client as well. Note there's a change here where we're using the server version of UniStrcat now which had different types (__le16 vs wchar_t) but it's not interpreting the value other than checking for 0, however we do need casts to keep sparse happy. Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org> Reviewed-by: Dave Kleikamp <dave.kleikamp@oracle.com> Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs/smb/client/smb2pdu.c')
-rw-r--r--fs/smb/client/smb2pdu.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/smb/client/smb2pdu.c b/fs/smb/client/smb2pdu.c
index d936c07a4b47..092b0087c9dc 100644
--- a/fs/smb/client/smb2pdu.c
+++ b/fs/smb/client/smb2pdu.c
@@ -2581,8 +2581,8 @@ alloc_path_with_tree_prefix(__le16 **out_path, int *out_size, int *out_len,
/* Do not append the separator if the path is empty */
if (path[0] != cpu_to_le16(0x0000)) {
- UniStrcat(*out_path, sep);
- UniStrcat(*out_path, path);
+ UniStrcat((wchar_t *)*out_path, (wchar_t *)sep);
+ UniStrcat((wchar_t *)*out_path, (wchar_t *)path);
}
unload_nls(cp);