Skip to content

Commit

Permalink
Bug 1004766. Make sure to enter the compartment of our new global bef…
Browse files Browse the repository at this point in the history
…ore working with it when wrapping global objects. r=nsm
  • Loading branch information
bzbarsky committed May 3, 2014
1 parent d7a767a commit 13ecba6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions dom/bindings/Codegen.py
Original file line number Diff line number Diff line change
Expand Up @@ -2966,6 +2966,9 @@ def definition_body(self):
aOptions,
aPrincipal);

// obj is a new global, so has a new compartment. Enter it
// before doing anything with it.
JSAutoCompartment ac(aCx, obj);
$*{unforgeable}

$*{slots}
Expand Down

0 comments on commit 13ecba6

Please sign in to comment.