Commit 15998c2b authored by Dan Kegel's avatar Dan Kegel Committed by Alexandre Julliard

cmd: Size buffer in create_full_path() correctly.

parent 60fe4dae
...@@ -319,7 +319,7 @@ static BOOL create_full_path(WCHAR* path) ...@@ -319,7 +319,7 @@ static BOOL create_full_path(WCHAR* path)
WCHAR *new_path; WCHAR *new_path;
BOOL ret = TRUE; BOOL ret = TRUE;
new_path = HeapAlloc(GetProcessHeap(),0,(strlenW(path) * sizeof(WCHAR))+1); new_path = HeapAlloc(GetProcessHeap(),0,(strlenW(path)+1) * sizeof(WCHAR));
strcpyW(new_path,path); strcpyW(new_path,path);
while ((len = strlenW(new_path)) && new_path[len - 1] == '\\') while ((len = strlenW(new_path)) && new_path[len - 1] == '\\')
......
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