Closed
Bug 1184541
Opened 9 years ago
Closed 9 years ago
Create a StructuredCloneHelperInternal and use it in the Console API
Categories
(Core :: DOM: Core & HTML, defect)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla42
Tracking | Status | |
---|---|---|
firefox42 | --- | fixed |
People
(Reporter: baku, Assigned: baku)
References
Details
Attachments
(1 file, 1 obsolete file)
19.28 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
Console API has a custom StructuredClone algorithm use because we transfer objects from workers to the main-thread as strings (except blobs).
Attachment #8634713 -
Flags: review?(bugs)
Assignee | ||
Comment 1•9 years ago
|
||
Attachment #8634713 -
Attachment is obsolete: true
Attachment #8634713 -
Flags: review?(bugs)
Attachment #8635282 -
Flags: review?(bugs)
Assignee | ||
Comment 2•9 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=94ab6e5ebf4c
Comment 3•9 years ago
|
||
Comment on attachment 8635282 [details] [diff] [review] clone1.patch >+StructuredCloneHelperInternal::Read(JSContext* aCx, >+ JS::MutableHandle<JS::Value> aValue) >+{ >+ MOZ_ASSERT(mBuffer, "Read() without Write() is not allowed."); >+ >+ if (!mBuffer->read(aCx, aValue, &gCallbacks, this)) { >+ return false; >+ } >+ >+ mBuffer = nullptr; Why we don't set buffer to null if read fails? I think we should.
Attachment #8635282 -
Flags: review?(bugs) → review+
Assignee | ||
Comment 4•9 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/aba974f71925
Comment 5•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/aba974f71925
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla42
I think this change caused bug 1264613. As the Structured Clone API stands, cloning an object as a non-object is not allowed: it confuses our object reference counts.
Updated•5 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•