Commit 4e1a01f1 authored by Evgeny Sinelnikov's avatar Evgeny Sinelnikov

Update sources 2.6.28 from 2.6.28.10

Fix buffer format byte on NT Rename/hardlink commit d5496f8996e53b6a6841c9bf1889d04dbcfc55b3
parent 868d7f02
Fix oops in cifs_dfs_ref.c when prefixpath is not reachable when using DFS. Fix oops in cifs_dfs_ref.c when prefixpath is not reachable when using DFS.
Fix "redzone overwritten" bug in cifs_put_tcon (CIFSTcon may allocate too
little memory for the "nativeFileSystem" field returned by the server
during mount).
Version 1.55 Version 1.55
------------ ------------
......
...@@ -2389,8 +2389,10 @@ winCreateHardLinkRetry: ...@@ -2389,8 +2389,10 @@ winCreateHardLinkRetry:
PATH_MAX, nls_codepage, remap); PATH_MAX, nls_codepage, remap);
name_len++; /* trailing null */ name_len++; /* trailing null */
name_len *= 2; name_len *= 2;
pSMB->OldFileName[name_len] = 0; /* pad */
pSMB->OldFileName[name_len + 1] = 0x04; /* protocol specifies ASCII buffer format (0x04) for unicode */
pSMB->OldFileName[name_len] = 0x04;
pSMB->OldFileName[name_len + 1] = 0x00; /* pad */
name_len2 = name_len2 =
cifsConvertToUCS((__le16 *)&pSMB->OldFileName[name_len + 2], cifsConvertToUCS((__le16 *)&pSMB->OldFileName[name_len + 2],
toName, PATH_MAX, nls_codepage, remap); toName, PATH_MAX, nls_codepage, remap);
......
...@@ -3585,7 +3585,7 @@ CIFSTCon(unsigned int xid, struct cifsSesInfo *ses, ...@@ -3585,7 +3585,7 @@ CIFSTCon(unsigned int xid, struct cifsSesInfo *ses,
BCC(smb_buffer_response)) { BCC(smb_buffer_response)) {
kfree(tcon->nativeFileSystem); kfree(tcon->nativeFileSystem);
tcon->nativeFileSystem = tcon->nativeFileSystem =
kzalloc(length + 2, GFP_KERNEL); kzalloc(2*(length + 1), GFP_KERNEL);
if (tcon->nativeFileSystem) if (tcon->nativeFileSystem)
cifs_strfromUCS_le( cifs_strfromUCS_le(
tcon->nativeFileSystem, tcon->nativeFileSystem,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment