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
ff0cea33
Commit
ff0cea33
authored
Sep 01, 2011
by
Jacek Caban
Committed by
Alexandre Julliard
Sep 01, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jscript: Added more SetInterfaceSafetyOptions tests and fixes.
parent
776e2783
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
1 deletion
+33
-1
jscript.c
dlls/jscript/jscript.c
+1
-1
jscript.c
dlls/jscript/tests/jscript.c
+32
-0
No files found.
dlls/jscript/jscript.c
View file @
ff0cea33
...
...
@@ -943,7 +943,7 @@ static HRESULT WINAPI JScriptSafety_SetInterfaceSafetyOptions(IObjectSafety *ifa
if
(
dwOptionSetMask
&
~
SUPPORTED_OPTIONS
)
return
E_FAIL
;
This
->
safeopt
=
dwEnabledOptions
&
dwEnabledOptions
;
This
->
safeopt
=
(
dwEnabledOptions
&
dwOptionSetMask
)
|
(
This
->
safeopt
&
~
dwOptionSetMask
)
|
INTERFACE_USES_DISPEX
;
return
S_OK
;
}
...
...
dlls/jscript/tests/jscript.c
View file @
ff0cea33
...
...
@@ -329,6 +329,38 @@ static void test_safety(IUnknown *unk)
ok
(
enabled
==
(
INTERFACESAFE_FOR_UNTRUSTED_DATA
|
INTERFACE_USES_DISPEX
|
INTERFACE_USES_SECURITY_MANAGER
),
"enabled=%x
\n
"
,
enabled
);
hres
=
IObjectSafety_SetInterfaceSafetyOptions
(
safety
,
&
IID_IActiveScriptParse
,
INTERFACESAFE_FOR_UNTRUSTED_DATA
,
0
);
ok
(
hres
==
S_OK
,
"SetInterfaceSafetyOptions failed: %08x
\n
"
,
hres
);
supported
=
enabled
=
0xdeadbeef
;
hres
=
IObjectSafety_GetInterfaceSafetyOptions
(
safety
,
&
IID_IActiveScriptParse
,
&
supported
,
&
enabled
);
ok
(
hres
==
S_OK
,
"GetInterfaceSafetyOptions failed: %08x
\n
"
,
hres
);
ok
(
supported
==
(
INTERFACESAFE_FOR_UNTRUSTED_DATA
|
INTERFACE_USES_DISPEX
|
INTERFACE_USES_SECURITY_MANAGER
),
"supported=%x
\n
"
,
supported
);
ok
(
enabled
==
(
INTERFACE_USES_DISPEX
|
INTERFACE_USES_SECURITY_MANAGER
),
"enabled=%x
\n
"
,
enabled
);
hres
=
IObjectSafety_SetInterfaceSafetyOptions
(
safety
,
&
IID_IActiveScriptParse
,
INTERFACESAFE_FOR_UNTRUSTED_DATA
|
INTERFACE_USES_DISPEX
|
INTERFACE_USES_SECURITY_MANAGER
,
0
);
ok
(
hres
==
S_OK
,
"SetInterfaceSafetyOptions failed: %08x
\n
"
,
hres
);
supported
=
enabled
=
0xdeadbeef
;
hres
=
IObjectSafety_GetInterfaceSafetyOptions
(
safety
,
&
IID_IActiveScriptParse
,
&
supported
,
&
enabled
);
ok
(
hres
==
S_OK
,
"GetInterfaceSafetyOptions failed: %08x
\n
"
,
hres
);
ok
(
supported
==
(
INTERFACESAFE_FOR_UNTRUSTED_DATA
|
INTERFACE_USES_DISPEX
|
INTERFACE_USES_SECURITY_MANAGER
),
"supported=%x
\n
"
,
supported
);
ok
(
enabled
==
INTERFACE_USES_DISPEX
,
"enabled=%x
\n
"
,
enabled
);
hres
=
IObjectSafety_SetInterfaceSafetyOptions
(
safety
,
&
IID_IActiveScriptParse
,
INTERFACE_USES_DISPEX
,
0
);
ok
(
hres
==
S_OK
,
"SetInterfaceSafetyOptions failed: %08x
\n
"
,
hres
);
supported
=
enabled
=
0xdeadbeef
;
hres
=
IObjectSafety_GetInterfaceSafetyOptions
(
safety
,
&
IID_IActiveScriptParse
,
&
supported
,
&
enabled
);
ok
(
hres
==
S_OK
,
"GetInterfaceSafetyOptions failed: %08x
\n
"
,
hres
);
ok
(
supported
==
(
INTERFACESAFE_FOR_UNTRUSTED_DATA
|
INTERFACE_USES_DISPEX
|
INTERFACE_USES_SECURITY_MANAGER
),
"supported=%x
\n
"
,
supported
);
ok
(
enabled
==
INTERFACE_USES_DISPEX
,
"enabled=%x
\n
"
,
enabled
);
IObjectSafety_Release
(
safety
);
}
...
...
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