Closed Bug 1127885 Opened 9 years ago Closed 9 years ago

Console API should display blobs when used in workers

Categories

(Core :: DOM: Core & HTML, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla38
Tracking Status
firefox38 --- fixed

People

(Reporter: baku, Assigned: baku)

Details

Attachments

(1 file)

Attached patch blob.patchSplinter Review
Currently we show a string, but blobs can be sent between threads and would be nice to support them.
Attachment #8557134 - Flags: review?(bugs)
We really need to stop having tons of different structured cloning implementations.
What we could have is some generic method which takes accepted SCTAG types as a param.
But that is something for a different bug.
Comment on attachment 8557134 [details] [diff] [review]
blob.patch


> ConsoleStructuredCloneCallbacksWrite(JSContext* aCx,
>                                      JSStructuredCloneWriter* aWriter,
>                                      JS::Handle<JSObject*> aObj,
>                                      void* aClosure)
> {
>+  ConsoleStructuredCloneData* data =
>+    static_cast<ConsoleStructuredCloneData*>(aClosure);
>+  MOZ_ASSERT(data);
Could we assert here that data->mParent is null to ensure that caller is using 
ConsoleStructuredCloneData correctly.
Attachment #8557134 - Flags: review?(bugs) → review+
(In reply to Olli Pettay [:smaug] from comment #1)
> We really need to stop having tons of different structured cloning
> implementations.
> What we could have is some generic method which takes accepted SCTAG types
> as a param.
> But that is something for a different bug.

Right. I filed bug 972973 for this months ago.
Part of this work has been done in MessagePort in workers patches.
Probably when that is landed, we can finish this merge.
(In reply to Phil Ringnalda (:philor) from comment #4)
> Backed out in
> https://hg.mozilla.org/integration/mozilla-inbound/rev/0674270dedae for
> hazard build bustage, apparently
> https://ftp-ssl.mozilla.org/pub/mozilla.org/firefox/tinderbox-builds/mozilla-
> inbound-linux64-br-haz/20150131101235/hazards.txt.gz is supposed to tell you
> why.

and sorry had to back this out again for harzard build bustage when this landed again. 

Bustage: https://treeherder.mozilla.org/logviewer.html#?job_id=6157281&repo=mozilla-inbound

hazard results: https://ftp-ssl.mozilla.org/pub/mozilla.org/b2g/tinderbox-builds/mozilla-inbound-linux64-b2g-haz/20150202035235
https://hg.mozilla.org/mozilla-central/rev/f6baaf87b073
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: