Closed Bug 448587 Opened 16 years ago Closed 16 years ago

SJOWs around functions don't resolve the 'prototype' property

Categories

(Core :: XPConnect, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla1.9.1a2

People

(Reporter: mrbkap, Assigned: mrbkap)

References

()

Details

(Whiteboard: [firebug-p2])

Attachments

(1 file)

From XPC_SJOW_GetOrSetProperty:

  // We don't deal with the following properties here.
  if (id == GetRTStringByIndex(cx, XPCJSRuntime::IDX_PROTOTYPE) ||
      id == GetRTStringByIndex(cx, XPCJSRuntime::IDX_TO_STRING)) {
    return JS_TRUE;
  }

jst, do you remember why we do this? This would affect any random 'prototype' property on a wrapped object and it bites us especially when the wrapped function is
Attached patch FixSplinter Review
This would be the obvious fix + a mochitest.
Assignee: nobody → mrbkap
Status: NEW → ASSIGNED
Attachment #331786 - Flags: superreview?(bzbarsky)
Attachment #331786 - Flags: review?(jst)
Attachment #331786 - Flags: superreview?(bzbarsky) → superreview+
Comment on attachment 331786 [details] [diff] [review]
Fix

I really don't remember exactly why that code is there, but I can't really imagine what it'd be needed for here as long as the property does get wrapped etc.
Attachment #331786 - Flags: review?(jst) → review+
This would be nice for Firebug...
Flags: wanted1.9.0.x?
Whiteboard: [firebug-p2]
Pushed to mozilla-central: http://hg.mozilla.org/mozilla-central/index.cgi/rev/3c09b73c94ed
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.1a2
Any news on which version of Firefox will have this fix?
See the "target milestone" field?
Flags: wanted1.9.0.x? → wanted1.9.0.x+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: