Marcus Meissner : kernel32: GetCurrentDirectoryW gets characters, not bytes.

Alexandre Julliard julliard at wine.codeweavers.com
Fri Jun 26 07:11:54 CDT 2015


Module: wine
Branch: master
Commit: c1d262f66d435a65ec5a517fe6c817ea20e54636
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=c1d262f66d435a65ec5a517fe6c817ea20e54636

Author: Marcus Meissner <marcus at jet.franken.de>
Date:   Fri Jun 26 09:01:27 2015 +0200

kernel32: GetCurrentDirectoryW gets characters, not bytes.

---

 dlls/kernel32/volume.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/kernel32/volume.c b/dlls/kernel32/volume.c
index 7cb245a..7a1dc11 100644
--- a/dlls/kernel32/volume.c
+++ b/dlls/kernel32/volume.c
@@ -1911,7 +1911,7 @@ BOOL WINAPI GetVolumePathNameW(LPCWSTR filename, LPWSTR volumepathname, DWORD bu
                 goto cleanup;
             }
         }
-        else if (GetCurrentDirectoryW( sizeof(cwdW), cwdW ))
+        else if (GetCurrentDirectoryW( sizeof(cwdW)/sizeof(cwdW[0]), cwdW ))
         {
             /* if the path is completely bogus then revert to the drive of the working directory */
             fallbackpathW[0] = cwdW[0];




More information about the wine-cvs mailing list