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
d93e2899
Commit
d93e2899
authored
Nov 08, 2023
by
Paul Gofman
Committed by
Alexandre Julliard
Nov 09, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernelbase: Return empty string from LoadStringW() if resource is not found.
parent
ad9303d8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
string.c
dlls/kernelbase/string.c
+7
-5
No files found.
dlls/kernelbase/string.c
View file @
d93e2899
...
@@ -1229,11 +1229,13 @@ INT WINAPI DECLSPEC_HOTPATCH LoadStringW(HINSTANCE instance, UINT resource_id, L
...
@@ -1229,11 +1229,13 @@ INT WINAPI DECLSPEC_HOTPATCH LoadStringW(HINSTANCE instance, UINT resource_id, L
if
(
!
buffer
)
if
(
!
buffer
)
return
0
;
return
0
;
/* Use loword (incremented by 1) as resourceid */
if
(
!
(
hrsrc
=
FindResourceW
(
instance
,
MAKEINTRESOURCEW
((
LOWORD
(
resource_id
)
>>
4
)
+
1
),
(
LPWSTR
)
RT_STRING
))
||
hrsrc
=
FindResourceW
(
instance
,
MAKEINTRESOURCEW
((
LOWORD
(
resource_id
)
>>
4
)
+
1
),
(
LPWSTR
)
RT_STRING
);
!
(
hmem
=
LoadResource
(
instance
,
hrsrc
)))
if
(
!
hrsrc
)
return
0
;
{
hmem
=
LoadResource
(
instance
,
hrsrc
);
TRACE
(
"Failed to load string.
\n
"
);
if
(
!
hmem
)
return
0
;
if
(
buflen
>
0
)
buffer
[
0
]
=
0
;
return
0
;
}
p
=
LockResource
(
hmem
);
p
=
LockResource
(
hmem
);
string_num
=
resource_id
&
0x000f
;
string_num
=
resource_id
&
0x000f
;
...
...
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