Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
bf823755
Commit
bf823755
authored
Feb 12, 2003
by
Sergei Turchanov
Committed by
Alexandre Julliard
Feb 12, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- _SHStrDupAA forgot about terminating '\0'.
- SHStrDupA adds extra terminator which is not needed as the length returned by MultiByteToWideChar(,,-1,,) already includes it.
parent
5e71f2d5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
string.c
dlls/shlwapi/string.c
+2
-2
No files found.
dlls/shlwapi/string.c
View file @
bf823755
...
...
@@ -1716,7 +1716,7 @@ static HRESULT WINAPI _SHStrDupAA(LPCSTR src, LPSTR * dest)
int
len
=
0
;
if
(
src
)
{
len
=
lstrlenA
(
src
)
;
len
=
lstrlenA
(
src
)
+
1
;
*
dest
=
CoTaskMemAlloc
(
len
);
}
else
{
*
dest
=
NULL
;
...
...
@@ -1753,7 +1753,7 @@ HRESULT WINAPI SHStrDupA(LPCSTR src, LPWSTR * dest)
int
len
=
0
;
if
(
src
)
{
len
=
(
MultiByteToWideChar
(
0
,
0
,
src
,
-
1
,
0
,
0
)
+
1
)
*
sizeof
(
WCHAR
);
len
=
MultiByteToWideChar
(
0
,
0
,
src
,
-
1
,
0
,
0
)
*
sizeof
(
WCHAR
);
*
dest
=
CoTaskMemAlloc
(
len
);
}
else
{
*
dest
=
NULL
;
...
...
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