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
0daa39fa
Commit
0daa39fa
authored
Aug 01, 2010
by
Thomas Mullaly
Committed by
Alexandre Julliard
Aug 17, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
urlmon: Added support for invalid flag combinations to CreateUri.
parent
b3ad7469
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
5 deletions
+13
-5
uri.c
dlls/urlmon/tests/uri.c
+3
-5
uri.c
dlls/urlmon/uri.c
+10
-0
No files found.
dlls/urlmon/tests/uri.c
View file @
0daa39fa
...
...
@@ -3683,11 +3683,9 @@ static void test_CreateUri_InvalidFlags(void) {
IUri
*
uri
=
(
void
*
)
0xdeadbeef
;
hr
=
pCreateUri
(
http_urlW
,
invalid_flag_tests
[
i
].
flags
,
0
,
&
uri
);
todo_wine
{
ok
(
hr
==
invalid_flag_tests
[
i
].
expected
,
"Error: CreateUri returned 0x%08x, expected 0x%08x, flags=0x%08x
\n
"
,
hr
,
invalid_flag_tests
[
i
].
expected
,
invalid_flag_tests
[
i
].
flags
);
}
todo_wine
{
ok
(
uri
==
NULL
,
"Error: expected the IUri to be NULL, but it was %p instead
\n
"
,
uri
);
}
ok
(
hr
==
invalid_flag_tests
[
i
].
expected
,
"Error: CreateUri returned 0x%08x, expected 0x%08x, flags=0x%08x
\n
"
,
hr
,
invalid_flag_tests
[
i
].
expected
,
invalid_flag_tests
[
i
].
flags
);
ok
(
uri
==
NULL
,
"Error: expected the IUri to be NULL, but it was %p instead
\n
"
,
uri
);
}
}
...
...
dlls/urlmon/uri.c
View file @
0daa39fa
...
...
@@ -3761,6 +3761,16 @@ HRESULT WINAPI CreateUri(LPCWSTR pwzURI, DWORD dwFlags, DWORD_PTR dwReserved, IU
return
E_INVALIDARG
;
}
/* Check for invalid flags. */
if
((
dwFlags
&
Uri_CREATE_DECODE_EXTRA_INFO
&&
dwFlags
&
Uri_CREATE_NO_DECODE_EXTRA_INFO
)
||
(
dwFlags
&
Uri_CREATE_CANONICALIZE
&&
dwFlags
&
Uri_CREATE_NO_CANONICALIZE
)
||
(
dwFlags
&
Uri_CREATE_CRACK_UNKNOWN_SCHEMES
&&
dwFlags
&
Uri_CREATE_NO_CRACK_UNKNOWN_SCHEMES
)
||
(
dwFlags
&
Uri_CREATE_PRE_PROCESS_HTML_URI
&&
dwFlags
&
Uri_CREATE_NO_PRE_PROCESS_HTML_URI
)
||
(
dwFlags
&
Uri_CREATE_IE_SETTINGS
&&
dwFlags
&
Uri_CREATE_NO_IE_SETTINGS
))
{
*
ppURI
=
NULL
;
return
E_INVALIDARG
;
}
ret
=
heap_alloc
(
sizeof
(
Uri
));
if
(
!
ret
)
return
E_OUTOFMEMORY
;
...
...
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