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
0db9f33b
Commit
0db9f33b
authored
May 30, 2023
by
Gabriel Ivăncescu
Committed by
Alexandre Julliard
May 30, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Handle protocols with no ports when checking target origin.
Signed-off-by:
Gabriel Ivăncescu
<
gabrielopcode@gmail.com
>
parent
11cc7af2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
htmlwindow.c
dlls/mshtml/htmlwindow.c
+12
-2
No files found.
dlls/mshtml/htmlwindow.c
View file @
0db9f33b
...
...
@@ -3161,6 +3161,7 @@ static HRESULT WINAPI window_private_matchMedia(IWineHTMLWindowPrivate *iface, B
static
HRESULT
check_target_origin
(
HTMLInnerWindow
*
window
,
const
WCHAR
*
target_origin
)
{
BOOL
no_port
=
FALSE
;
IUri
*
uri
,
*
target
;
DWORD
port
,
port2
;
BSTR
bstr
,
bstr2
;
...
...
@@ -3219,11 +3220,20 @@ static HRESULT check_target_origin(HTMLInnerWindow *window, const WCHAR *target_
goto
done
;
hres
=
IUri_GetPort
(
uri
,
&
port
);
if
(
hres
!=
S_OK
)
if
(
hres
!=
S_OK
)
{
if
(
FAILED
(
hres
))
goto
done
;
no_port
=
TRUE
;
/* some protocols don't have ports (e.g. res) */
}
hres
=
IUri_GetPort
(
target
,
&
port2
);
if
(
hres
==
S_OK
&&
port
!=
port2
)
if
(
hres
!=
S_OK
)
{
if
(
FAILED
(
hres
))
goto
done
;
if
(
no_port
)
hres
=
S_OK
;
}
else
if
(
no_port
||
port
!=
port2
)
{
hres
=
S_FALSE
;
}
done:
IUri_Release
(
target
);
...
...
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