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
4bbfd838
Commit
4bbfd838
authored
Feb 16, 2024
by
Shaun Ren
Committed by
Alexandre Julliard
Feb 20, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sapi: Handle zero-length attributes correctly in ISpObjectTokenCategory::EnumTokens.
parent
5243f2e8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
1 deletion
+11
-1
token.c
dlls/sapi/tests/token.c
+10
-0
token.c
dlls/sapi/token.c
+1
-1
No files found.
dlls/sapi/tests/token.c
View file @
4bbfd838
...
@@ -205,6 +205,16 @@ static void test_token_category(void)
...
@@ -205,6 +205,16 @@ static void test_token_category(void)
IEnumSpObjectTokens_Release
(
enum_tokens
);
IEnumSpObjectTokens_Release
(
enum_tokens
);
hr
=
ISpObjectTokenCategory_EnumTokens
(
cat
,
L""
,
NULL
,
&
enum_tokens
);
ok
(
hr
==
S_OK
,
"got %08lx
\n
"
,
hr
);
count
=
0xdeadbeef
;
hr
=
IEnumSpObjectTokens_GetCount
(
enum_tokens
,
&
count
);
ok
(
hr
==
S_OK
,
"got %08lx
\n
"
,
hr
);
ok
(
count
==
5
,
"got %lu
\n
"
,
count
);
IEnumSpObjectTokens_Release
(
enum_tokens
);
hr
=
ISpObjectTokenCategory_EnumTokens
(
cat
,
L"Language=409"
,
NULL
,
&
enum_tokens
);
hr
=
ISpObjectTokenCategory_EnumTokens
(
cat
,
L"Language=409"
,
NULL
,
&
enum_tokens
);
ok
(
hr
==
S_OK
,
"got %08lx
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"got %08lx
\n
"
,
hr
);
...
...
dlls/sapi/token.c
View file @
4bbfd838
...
@@ -947,7 +947,7 @@ static HRESULT score_attributes( ISpObjectToken *token, const WCHAR *attrs,
...
@@ -947,7 +947,7 @@ static HRESULT score_attributes( ISpObjectToken *token, const WCHAR *attrs,
unsigned
int
i
,
j
;
unsigned
int
i
,
j
;
HRESULT
hr
;
HRESULT
hr
;
if
(
!
attrs
)
if
(
!
attrs
||
!*
attrs
)
{
{
*
score
=
1
;
*
score
=
1
;
return
S_OK
;
return
S_OK
;
...
...
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