From 275b9f21ac009e4c75b2c26b82a14b42e6e3313f Mon Sep 17 00:00:00 2001 From: Blake Kaplan Date: Mon, 4 Jan 2010 23:00:29 -0800 Subject: [PATCH] Bug 533635 - Don't automatically wrap iframe elements in XOWs. Rely on XPConnect wrapping for the right security wrappers. r=peterv --- dom/tests/mochitest/general/Makefile.in | 2 + .../general/file_frameElementWrapping.html | 26 +++++++++++++ .../general/test_frameElementWrapping.html | 38 +++++++++++++++++++ js/src/xpconnect/src/XPCWrapper.h | 7 ---- 4 files changed, 66 insertions(+), 7 deletions(-) create mode 100644 dom/tests/mochitest/general/file_frameElementWrapping.html create mode 100644 dom/tests/mochitest/general/test_frameElementWrapping.html diff --git a/dom/tests/mochitest/general/Makefile.in b/dom/tests/mochitest/general/Makefile.in index 43eb0afff5c..fe75951a599 100644 --- a/dom/tests/mochitest/general/Makefile.in +++ b/dom/tests/mochitest/general/Makefile.in @@ -59,6 +59,8 @@ _TEST_FILES = \ test_clipboard_events.html \ test_focusrings.xul \ test_nodesFromRect.html \ + test_frameElementWrapping.html \ + file_frameElementWrapping.html \ $(NULL) libs:: $(_TEST_FILES) diff --git a/dom/tests/mochitest/general/file_frameElementWrapping.html b/dom/tests/mochitest/general/file_frameElementWrapping.html new file mode 100644 index 00000000000..7d30a5e117d --- /dev/null +++ b/dom/tests/mochitest/general/file_frameElementWrapping.html @@ -0,0 +1,26 @@ + + + diff --git a/dom/tests/mochitest/general/test_frameElementWrapping.html b/dom/tests/mochitest/general/test_frameElementWrapping.html new file mode 100644 index 00000000000..72f496cccc0 --- /dev/null +++ b/dom/tests/mochitest/general/test_frameElementWrapping.html @@ -0,0 +1,38 @@ + + + + Test for location object behaviors + + + + + +

+ + +
+
+
+ + diff --git a/js/src/xpconnect/src/XPCWrapper.h b/js/src/xpconnect/src/XPCWrapper.h index f45d52192a4..fd3fa8163db 100644 --- a/js/src/xpconnect/src/XPCWrapper.h +++ b/js/src/xpconnect/src/XPCWrapper.h @@ -109,13 +109,6 @@ ClassNeedsXOW(const char *name) return strcmp(++name, "indow") == 0; case 'L': return strcmp(++name, "ocation") == 0; - case 'H': - if (strncmp(++name, "TML", 3)) - break; - name += 3; - if (*name == 'I') - ++name; - return strcmp(name, "FrameElement") == 0; default: break; }