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
739ff120
Commit
739ff120
authored
Mar 29, 2011
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 29, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Store security manager in HTMLWindow instead of HTMLDocumentNode.
parent
643c66ba
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
13 deletions
+15
-13
htmldoc.c
dlls/mshtml/htmldoc.c
+0
-9
htmlwindow.c
dlls/mshtml/htmlwindow.c
+10
-0
mshtml_private.h
dlls/mshtml/mshtml_private.h
+2
-1
secmgr.c
dlls/mshtml/secmgr.c
+3
-3
No files found.
dlls/mshtml/htmldoc.c
View file @
739ff120
...
...
@@ -1912,8 +1912,6 @@ static void HTMLDocumentNode_destructor(HTMLDOMNode *iface)
release_nsevents
(
This
);
if
(
This
->
catmgr
)
ICatInformation_Release
(
This
->
catmgr
);
if
(
This
->
secmgr
)
IInternetSecurityManager_Release
(
This
->
secmgr
);
detach_selection
(
This
);
detach_ranges
(
This
);
...
...
@@ -2013,7 +2011,6 @@ static HTMLDocumentNode *alloc_doc_node(HTMLDocumentObj *doc_obj, HTMLWindow *wi
HRESULT
create_doc_from_nsdoc
(
nsIDOMHTMLDocument
*
nsdoc
,
HTMLDocumentObj
*
doc_obj
,
HTMLWindow
*
window
,
HTMLDocumentNode
**
ret
)
{
HTMLDocumentNode
*
doc
;
HRESULT
hres
;
doc
=
alloc_doc_node
(
doc_obj
,
window
);
if
(
!
doc
)
...
...
@@ -2030,12 +2027,6 @@ HRESULT create_doc_from_nsdoc(nsIDOMHTMLDocument *nsdoc, HTMLDocumentObj *doc_ob
doc
->
node
.
vtbl
=
&
HTMLDocumentNodeImplVtbl
;
doc
->
node
.
cp_container
=
&
doc
->
basedoc
.
cp_container
;
hres
=
CoInternetCreateSecurityManager
(
NULL
,
&
doc
->
secmgr
,
0
);
if
(
FAILED
(
hres
))
{
htmldoc_release
(
&
doc
->
basedoc
);
return
hres
;
}
*
ret
=
doc
;
return
S_OK
;
}
...
...
dlls/mshtml/htmlwindow.c
View file @
739ff120
...
...
@@ -236,6 +236,9 @@ static ULONG WINAPI HTMLWindow2_Release(IHTMLWindow2 *iface)
window_set_docnode
(
This
,
NULL
);
release_children
(
This
);
if
(
This
->
secmgr
)
IInternetSecurityManager_Release
(
This
->
secmgr
);
if
(
This
->
frame_element
)
This
->
frame_element
->
content_window
=
NULL
;
...
...
@@ -2217,6 +2220,7 @@ static dispex_static_data_t HTMLWindow_dispex = {
HRESULT
HTMLWindow_Create
(
HTMLDocumentObj
*
doc_obj
,
nsIDOMWindow
*
nswindow
,
HTMLWindow
*
parent
,
HTMLWindow
**
ret
)
{
HTMLWindow
*
window
;
HRESULT
hres
;
window
=
heap_alloc_zero
(
sizeof
(
HTMLWindow
));
if
(
!
window
)
...
...
@@ -2251,6 +2255,12 @@ HRESULT HTMLWindow_Create(HTMLDocumentObj *doc_obj, nsIDOMWindow *nswindow, HTML
window
->
readystate
=
READYSTATE_UNINITIALIZED
;
list_init
(
&
window
->
script_hosts
);
hres
=
CoInternetCreateSecurityManager
(
NULL
,
&
window
->
secmgr
,
0
);
if
(
FAILED
(
hres
))
{
IHTMLWindow2_Release
(
&
window
->
IHTMLWindow2_iface
);
return
hres
;
}
window
->
task_magic
=
get_task_target_magic
();
update_window_doc
(
window
);
...
...
dlls/mshtml/mshtml_private.h
View file @
739ff120
...
...
@@ -295,6 +295,8 @@ struct HTMLWindow {
SCRIPTMODE
scriptmode
;
struct
list
script_hosts
;
IInternetSecurityManager
*
secmgr
;
HTMLOptionElementFactory
*
option_factory
;
HTMLImageElementFactory
*
image_factory
;
HTMLLocation
*
location
;
...
...
@@ -611,7 +613,6 @@ struct HTMLDocumentNode {
BOOL
content_ready
;
event_target_t
*
body_event_target
;
IInternetSecurityManager
*
secmgr
;
ICatInformation
*
catmgr
;
nsDocumentEventListener
*
nsevent_listener
;
BOOL
*
event_vector
;
...
...
dlls/mshtml/secmgr.c
View file @
739ff120
...
...
@@ -83,7 +83,7 @@ static HRESULT WINAPI InternetHostSecurityManager_ProcessUrlAction(IInternetHost
url
=
This
->
basedoc
.
window
->
url
?
This
->
basedoc
.
window
->
url
:
about_blankW
;
return
IInternetSecurityManager_ProcessUrlAction
(
This
->
secmgr
,
url
,
dwAction
,
pPolicy
,
cbPolicy
,
return
IInternetSecurityManager_ProcessUrlAction
(
This
->
basedoc
.
window
->
secmgr
,
url
,
dwAction
,
pPolicy
,
cbPolicy
,
pContext
,
cbContext
,
dwFlags
,
dwReserved
);
}
...
...
@@ -121,7 +121,7 @@ static HRESULT confirm_safety(HTMLDocumentNode *This, const WCHAR *url, struct C
/* FIXME: Check URLACTION_ACTIVEX_OVERRIDE_SCRIPT_SAFETY */
hres
=
IInternetSecurityManager_ProcessUrlAction
(
This
->
secmgr
,
url
,
URLACTION_SCRIPT_SAFE_ACTIVEX
,
hres
=
IInternetSecurityManager_ProcessUrlAction
(
This
->
basedoc
.
window
->
secmgr
,
url
,
URLACTION_SCRIPT_SAFE_ACTIVEX
,
(
BYTE
*
)
&
policy
,
sizeof
(
policy
),
NULL
,
0
,
0
,
0
);
if
(
FAILED
(
hres
)
||
policy
!=
URLPOLICY_ALLOW
)
{
*
ret
=
URLPOLICY_DISALLOW
;
...
...
@@ -187,7 +187,7 @@ static HRESULT WINAPI InternetHostSecurityManager_QueryCustomPolicy(IInternetHos
url
=
This
->
basedoc
.
window
->
url
?
This
->
basedoc
.
window
->
url
:
about_blankW
;
hres
=
IInternetSecurityManager_QueryCustomPolicy
(
This
->
secmgr
,
url
,
guidKey
,
ppPolicy
,
pcbPolicy
,
hres
=
IInternetSecurityManager_QueryCustomPolicy
(
This
->
basedoc
.
window
->
secmgr
,
url
,
guidKey
,
ppPolicy
,
pcbPolicy
,
pContext
,
cbContext
,
dwReserved
);
if
(
hres
!=
HRESULT_FROM_WIN32
(
ERROR_NOT_FOUND
))
return
hres
;
...
...
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