Closed
Bug 788149
Opened 13 years ago
Closed 13 years ago
Empty dictionary for worker objects
Categories
(Core :: DOM: Core & HTML, defect)
Tracking
()
RESOLVED
FIXED
mozilla18
People
(Reporter: baku, Assigned: bzbarsky)
References
Details
Attachments
(3 files)
|
4.25 KB,
text/plain
|
Details | |
|
1.31 KB,
patch
|
Details | Diff | Splinter Review | |
|
6.49 KB,
patch
|
peterv
:
review+
|
Details | Diff | Splinter Review |
Applying the attached patch, this is the output that I see:
TEST_PATH=dom/workers/test/test_xhr_params.html make -C ../build/ mochitest-plain
BAKU CONSTRUCTOR: 1 0
TEST-PASS | unknown test url | XHR exists!
TEST-PASS | unknown test url | mozAnon == true - true should equal true
...
Then, refreshing the page:
BAKU CONSTRUCTOR: 0 0
TEST-PASS | unknown test url | XHR exists!
TEST-UNEXPECTED-FAIL | unknown test url | mozAnon == true - got false, expected true
...
The MozXMLHttpRequestParametersWorkers seems empty:
printf("BAKU CONSTRUCTOR: %d %d\n", aParams.mozAnon, aParams.mozSystem);
| Assignee | ||
Comment 1•13 years ago
|
||
Stepping through this on the reload, I see:
JS_HasPropertyById(cx, &val.toObject(), mozAnon_id, &found)
(gdb) p found
$1 = 0
I wonder... We end up with separate jsruntimes for the different workers, don't we? So we can't actually use jsid here, I bet. :(
| Reporter | ||
Comment 2•13 years ago
|
||
yep, Any worker has a separated JSRuntime.
Any implication using JS_HasProperty(JSContext *cx, JSObject *obj, const char *name, JSBool *foundp) ?
| Assignee | ||
Comment 3•13 years ago
|
||
Well, yes, it's slower. ;)
Patch coming up to do just that on workers, though. I'll include a variant of the attached test that fails reliably without requiring a reload.
| Assignee | ||
Comment 4•13 years ago
|
||
Actually, maybe it's better to just land the test as part of bug 761227. I'll just attach a diff against the test patch in this bug.
| Assignee | ||
Comment 5•13 years ago
|
||
| Assignee | ||
Comment 6•13 years ago
|
||
Attachment #658077 -
Flags: review?(peterv)
| Assignee | ||
Updated•13 years ago
|
Assignee: nobody → bzbarsky
Whiteboard: [need review]
Updated•13 years ago
|
Attachment #658077 -
Flags: review?(peterv) → review+
| Assignee | ||
Comment 7•13 years ago
|
||
http://hg.mozilla.org/integration/mozilla-inbound/rev/73642fc72b2e
Still needs a test, but I assume that will land as part of bug 761227?
Flags: in-testsuite?
Whiteboard: [need review]
Target Milestone: --- → mozilla18
Comment 8•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•