Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
67cfcfb9
Commit
67cfcfb9
authored
Sep 02, 2004
by
Mike McCormack
Committed by
Alexandre Julliard
Sep 02, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use the ACP define in MB/WC conversion functions.
parent
28a8caca
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
23 deletions
+23
-23
path.c
dlls/shlwapi/path.c
+23
-23
No files found.
dlls/shlwapi/path.c
View file @
67cfcfb9
...
...
@@ -140,11 +140,11 @@ LPSTR WINAPI PathCombineA(LPSTR lpszDest, LPCSTR lpszDir, LPCSTR lpszFile)
WCHAR
szDir
[
MAX_PATH
];
WCHAR
szFile
[
MAX_PATH
];
if
(
lpszDir
)
MultiByteToWideChar
(
0
,
0
,
lpszDir
,
-
1
,
szDir
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszDir
,
-
1
,
szDir
,
MAX_PATH
);
if
(
lpszFile
)
MultiByteToWideChar
(
0
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
);
PathCombineW
(
szDest
,
lpszDir
?
szDir
:
NULL
,
lpszFile
?
szFile
:
NULL
);
WideCharToMultiByte
(
0
,
0
,
szDest
,
-
1
,
lpszDest
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szDest
,
-
1
,
lpszDest
,
MAX_PATH
,
0
,
0
);
}
return
lpszDest
;
}
...
...
@@ -1125,10 +1125,10 @@ BOOL WINAPI PathFileExistsDefExtA(LPSTR lpszPath,DWORD dwWhich)
if
(
lpszPath
)
{
WCHAR
szPath
[
MAX_PATH
];
MultiByteToWideChar
(
0
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
bRet
=
PathFileExistsDefExtW
(
szPath
,
dwWhich
);
if
(
bRet
)
WideCharToMultiByte
(
0
,
0
,
szPath
,
-
1
,
lpszPath
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szPath
,
-
1
,
lpszPath
,
MAX_PATH
,
0
,
0
);
}
return
bRet
;
}
...
...
@@ -1238,7 +1238,7 @@ BOOL WINAPI PathFindOnPathExA(LPSTR lpszFile,LPCSTR *lppszOtherDirs,DWORD dwWhic
if
(
!
lpszFile
||
!
PathIsFileSpecA
(
lpszFile
))
return
FALSE
;
MultiByteToWideChar
(
0
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
);
/* Search provided directories first */
if
(
lppszOtherDirs
&&
*
lppszOtherDirs
)
...
...
@@ -1248,11 +1248,11 @@ BOOL WINAPI PathFindOnPathExA(LPSTR lpszFile,LPCSTR *lppszOtherDirs,DWORD dwWhic
while
(
lpszOtherPath
&&
*
lpszOtherPath
&&
(
*
lpszOtherPath
)[
0
])
{
MultiByteToWideChar
(
0
,
0
,
*
lpszOtherPath
,
-
1
,
szOther
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
*
lpszOtherPath
,
-
1
,
szOther
,
MAX_PATH
);
PathCombineW
(
buff
,
szOther
,
szFile
);
if
(
PathFileExistsDefExtW
(
buff
,
dwWhich
))
{
WideCharToMultiByte
(
0
,
0
,
buff
,
-
1
,
lpszFile
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
buff
,
-
1
,
lpszFile
,
MAX_PATH
,
0
,
0
);
return
TRUE
;
}
lpszOtherPath
++
;
...
...
@@ -1261,7 +1261,7 @@ BOOL WINAPI PathFindOnPathExA(LPSTR lpszFile,LPCSTR *lppszOtherDirs,DWORD dwWhic
/* Not found, try system and path dirs */
if
(
SHLWAPI_PathFindInOtherDirs
(
szFile
,
dwWhich
))
{
WideCharToMultiByte
(
0
,
0
,
szFile
,
-
1
,
lpszFile
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szFile
,
-
1
,
lpszFile
,
MAX_PATH
,
0
,
0
);
return
TRUE
;
}
return
FALSE
;
...
...
@@ -1368,10 +1368,10 @@ BOOL WINAPI PathCompactPathExA(LPSTR lpszDest, LPCSTR lpszPath,
WCHAR
szPath
[
MAX_PATH
];
WCHAR
szDest
[
MAX_PATH
];
MultiByteToWideChar
(
0
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
szDest
[
0
]
=
'\0'
;
bRet
=
PathCompactPathExW
(
szDest
,
szPath
,
cchMax
,
dwFlags
);
WideCharToMultiByte
(
0
,
0
,
szDest
,
-
1
,
lpszDest
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szDest
,
-
1
,
lpszDest
,
MAX_PATH
,
0
,
0
);
}
return
bRet
;
}
...
...
@@ -2338,9 +2338,9 @@ BOOL WINAPI PathCanonicalizeA(LPSTR lpszBuf, LPCSTR lpszPath)
{
WCHAR
szPath
[
MAX_PATH
];
WCHAR
szBuff
[
MAX_PATH
];
MultiByteToWideChar
(
0
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
bRet
=
PathCanonicalizeW
(
szBuff
,
szPath
);
WideCharToMultiByte
(
0
,
0
,
szBuff
,
-
1
,
lpszBuf
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szBuff
,
-
1
,
lpszBuf
,
MAX_PATH
,
0
,
0
);
}
return
bRet
;
}
...
...
@@ -2778,9 +2778,9 @@ BOOL WINAPI PathCompactPathA(HDC hDC, LPSTR lpszPath, UINT dx)
if
(
lpszPath
)
{
WCHAR
szPath
[
MAX_PATH
];
MultiByteToWideChar
(
0
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
bRet
=
PathCompactPathW
(
hDC
,
szPath
,
dx
);
WideCharToMultiByte
(
0
,
0
,
szPath
,
-
1
,
lpszPath
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szPath
,
-
1
,
lpszPath
,
MAX_PATH
,
0
,
0
);
}
return
bRet
;
}
...
...
@@ -3010,7 +3010,7 @@ BOOL WINAPI PathMakeSystemFolderA(LPCSTR lpszPath)
if
(
lpszPath
&&
*
lpszPath
)
{
WCHAR
szPath
[
MAX_PATH
];
MultiByteToWideChar
(
0
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
bRet
=
PathMakeSystemFolderW
(
szPath
);
}
return
bRet
;
...
...
@@ -3326,10 +3326,10 @@ BOOL WINAPI PathRelativePathToA(LPSTR lpszPath, LPCSTR lpszFrom, DWORD dwAttrFro
WCHAR
szPath
[
MAX_PATH
];
WCHAR
szFrom
[
MAX_PATH
];
WCHAR
szTo
[
MAX_PATH
];
MultiByteToWideChar
(
0
,
0
,
lpszFrom
,
-
1
,
szFrom
,
MAX_PATH
);
MultiByteToWideChar
(
0
,
0
,
lpszTo
,
-
1
,
szTo
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszFrom
,
-
1
,
szFrom
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszTo
,
-
1
,
szTo
,
MAX_PATH
);
bRet
=
PathRelativePathToW
(
szPath
,
szFrom
,
dwAttrFrom
,
szTo
,
dwAttrTo
);
WideCharToMultiByte
(
0
,
0
,
szPath
,
-
1
,
lpszPath
,
MAX_PATH
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szPath
,
-
1
,
lpszPath
,
MAX_PATH
,
0
,
0
);
}
return
bRet
;
}
...
...
@@ -3475,7 +3475,7 @@ VOID WINAPI PathSetDlgItemPathA(HWND hDlg, int id, LPCSTR lpszPath)
TRACE
(
"(%p,%8x,%s)
\n
"
,
hDlg
,
id
,
debugstr_a
(
lpszPath
));
if
(
lpszPath
)
MultiByteToWideChar
(
0
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
else
szPath
[
0
]
=
'\0'
;
PathSetDlgItemPathW
(
hDlg
,
id
,
szPath
);
...
...
@@ -3679,7 +3679,7 @@ BOOL WINAPI PathIsDirectoryEmptyA(LPCSTR lpszPath)
if
(
lpszPath
)
{
WCHAR
szPath
[
MAX_PATH
];
MultiByteToWideChar
(
0
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszPath
,
-
1
,
szPath
,
MAX_PATH
);
bRet
=
PathIsDirectoryEmptyW
(
szPath
);
}
return
bRet
;
...
...
@@ -3896,10 +3896,10 @@ HRESULT WINAPI SHGetWebFolderFilePathA(LPCSTR lpszFile, LPSTR lpszPath, DWORD dw
TRACE
(
"(%s,%p,%ld)
\n
"
,
lpszFile
,
lpszPath
,
dwPathLen
);
MultiByteToWideChar
(
0
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
);
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
);
szPath
[
0
]
=
'\0'
;
hRet
=
SHGetWebFolderFilePathW
(
szFile
,
szPath
,
dwPathLen
);
WideCharToMultiByte
(
0
,
0
,
szPath
,
-
1
,
lpszPath
,
dwPathLen
,
0
,
0
);
WideCharToMultiByte
(
CP_ACP
,
0
,
szPath
,
-
1
,
lpszPath
,
dwPathLen
,
0
,
0
);
return
hRet
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment