Closed Bug 671080 Opened 13 years ago Closed 13 years ago

Add assertion checking to ensure no unintentional cross-compartment wrappers are created

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla8

People

(Reporter: billm, Assigned: billm)

References

Details

Attachments

(1 file, 1 obsolete file)

Attached patch assertions (obsolete) — Splinter Review
Bug 670702 has evidence that some non-cross compartment JSWrappers have pointers outside their compartment. Blake confirms that this is not expected. This patch adds some additional opt-mode assertions to try and narrow down the code creating these pointers.

I'm sorry about how gross the check is. Unfortunately, we're not allowed to get the compartment for static strings, since they're not part of the GC heap.
Attachment #545480 - Flags: review?(mrbkap)
Attached patch nicer patchSplinter Review
Since the priv field can't be a string, this patch is shorter.
Assignee: general → wmccloskey
Attachment #545480 - Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #545485 - Flags: review?(mrbkap)
Attachment #545480 - Flags: review?(mrbkap)
Attachment #545485 - Flags: review?(mrbkap) → review+
Whiteboard: [inbound]
http://hg.mozilla.org/mozilla-central/rev/4fc08ab607db
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Whiteboard: [inbound]
Target Milestone: --- → mozilla8
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: