gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] /srv/bzr/gnash/trunk r12195: loadPolicyFile and allowInse


From: Rob Savoye
Subject: [Gnash-commit] /srv/bzr/gnash/trunk r12195: loadPolicyFile and allowInsecureDomain don't exist until swf v7.
Date: Fri, 21 May 2010 12:10:27 -0500
User-agent: Bazaar (2.0.3)

------------------------------------------------------------
revno: 12195
committer: Rob Savoye <address@hidden>
branch nick: trunk
timestamp: Fri 2010-05-21 12:10:27 -0500
message:
  loadPolicyFile and allowInsecureDomain don't exist until swf v7.
modified:
  libcore/asobj/flash/system/System_as.cpp
  testsuite/actionscript.all/System.as
=== modified file 'libcore/asobj/flash/system/System_as.cpp'
--- a/libcore/asobj/flash/system/System_as.cpp  2010-05-21 07:16:17 +0000
+++ b/libcore/asobj/flash/system/System_as.cpp  2010-05-21 17:10:27 +0000
@@ -97,11 +97,16 @@
     VM& vm = getVM(o);
     o.init_member("allowDomain", vm.getNative(12, 0));
 
+    const int swf7Flags = PropFlags::dontDelete | PropFlags::dontEnum
+        | PropFlags::readOnly | PropFlags::onlySWF7Up;
+
     Global_as& gl = getGlobal(o);
     o.init_member("allowInsecureDomain",
-                  gl.createFunction(system_security_allowinsecuredomain));
+                  gl.createFunction(system_security_allowinsecuredomain),
+                  swf7Flags);
     o.init_member("loadPolicyFile",
-                  gl.createFunction(system_security_loadpolicyfile));
+                  gl.createFunction(system_security_loadpolicyfile),
+                  swf7Flags);
 }
 
 void

=== modified file 'testsuite/actionscript.all/System.as'
--- a/testsuite/actionscript.all/System.as      2010-01-11 06:41:38 +0000
+++ b/testsuite/actionscript.all/System.as      2010-05-21 17:10:27 +0000
@@ -66,12 +66,6 @@
 check_equals (typeof(System.__proto__), 'object');
 check_equals (System.__proto__, Object.prototype)
 
-// test the System::security.allowDomain method
-check_equals ( typeof(System.security.allowDomain), 'function' );
-
-// test the System.security.loadPolicyFile method
-check_equals ( typeof(System.security.loadPolicyFile), 'function');
-
 // test the System.setClipboard method
 check_equals ( typeof(System.setClipboard), 'function');
 
@@ -80,6 +74,12 @@
 
 #if OUTPUT_VERSION >= 7
 
+// test the System::security.allowDomain method
+check_equals ( typeof(System.security.allowDomain), 'function' );
+
+// test the System.security.loadPolicyFile method
+check_equals ( typeof(System.security.loadPolicyFile), 'function');
+
 // test the System.security.allowInsecureDomain method
 // added in player 7
 check_equals ( typeof(System.security.allowInsecureDomain), 'function' );
@@ -200,8 +200,8 @@
  check_totals(93);
 #else
 # if OUTPUT_VERSION == 6
-   check_totals(92);
+   check_totals(90);
 # else
-   check_totals(59);
+   check_totals(57);
 # endif
 #endif


reply via email to

[Prev in Thread] Current Thread [Next in Thread]