Closed
Bug 823789
Opened 12 years ago
Closed 12 years ago
geolocation.watchposition position_options ignored
Categories
(Core :: DOM: Geolocation, defect)
Tracking
()
People
(Reporter: m1, Assigned: jdm)
References
Details
Attachments
(1 file)
7.63 KB,
patch
|
dougt
:
review+
bajaj
:
approval-mozilla-aurora+
bajaj
:
approval-mozilla-b2g18+
|
Details | Diff | Splinter Review |
position_options are getting lost when the switch from content to b2g process occurs.
Net effect is that enableHighAccuracy,timeout,maximumAge does not work when running from a content process. Works fine when OOP is disabled.
Quick Analysis:
1) Content process calls
http://mxr.mozilla.org/mozilla-beta/source/dom/src/geolocation/nsGeolocation.cpp#932
2) On the parent process side we then forge a dummy position_options of JSVAL_VOID (http://mxr.mozilla.org/mozilla-beta/source/dom/ipc/ContentParent.cpp#1903) and pass that void along to the nsIGeolocationProviders
Updated•12 years ago
|
Component: General → Geolocation
Product: Boot2Gecko → Core
Comment 1•12 years ago
|
||
josh, you interested in an e10s bug?
Updated•12 years ago
|
blocking-basecamp: ? → -
tracking-b2g18:
--- → +
Assignee | ||
Updated•12 years ago
|
Assignee: nobody → josh
Assignee | ||
Comment 2•12 years ago
|
||
Michael, are you positive that timeout and maximumAge don't work? There's no reason I can see that they should not, since all of the relevant bits of code are executed in the content process.
Reporter | ||
Comment 3•12 years ago
|
||
Yep, pretty sure. nsIGeolocationProviders run in the system process, and the position_options are getting lost [1] as they exit the content process, so the geolocation providers never get them.
[1] http://mxr.mozilla.org/mozilla-beta/source/dom/ipc/ContentParent.cpp#1903
Assignee | ||
Comment 4•12 years ago
|
||
Indeed, I have a test which demonstrates that timeouts certainly work in content processes in contrived conditions.
Assignee | ||
Comment 5•12 years ago
|
||
Michael, the providers don't need the timeout values. The timeouts are only needed in the content process where the timers run.
Assignee | ||
Updated•12 years ago
|
Attachment #695517 -
Flags: review?(doug.turner)
Reporter | ||
Comment 6•12 years ago
|
||
(In reply to Josh Matthews [:jdm] from comment #5)
> Michael, the providers don't need the timeout values. The timeouts are only
> needed in the content process where the timers run.
Ah, missed that. Sorry. I checked with the original reporter for this issue and looks like only real complaint was the lack of the enableHighAccuracy arriving at the provider. The rest was creative extrapolation. :)
So attachment 695517 [details] [diff] [review] lgtm!
Comment 7•12 years ago
|
||
Comment on attachment 695517 [details] [diff] [review]
Pass enableHighAccuracy geolocation changes to the chrome process.
Review of attachment 695517 [details] [diff] [review]:
-----------------------------------------------------------------
::: dom/tests/unit/test_geolocation_timeout.js
@@ +51,5 @@
> +
> + if (Cc["@mozilla.org/xre/app-info;1"].getService(Ci.nsIXULRuntime)
> + .processType == Ci.nsIXULRuntime.PROCESS_TYPE_DEFAULT) {
> + var prefs = Cc["@mozilla.org/preferences-service;1"].getService(Ci.nsIPrefBranch);
> + prefs.setCharPref("geo.wifi.uri", "http://localhost:4444/geo");
trailing ws
::: dom/tests/unit/test_geolocation_timeout_wrap.js
@@ +2,5 @@
> +const Ci = Components.interfaces;
> +
> +function run_test() {
> + var prefs = Cc["@mozilla.org/preferences-service;1"].getService(Ci.nsIPrefBranch);
> + prefs.setCharPref("geo.wifi.uri", "http://localhost:4444/geo");
trailing ws
Attachment #695517 -
Flags: review?(doug.turner) → review+
Assignee | ||
Comment 8•12 years ago
|
||
Assignee | ||
Comment 9•12 years ago
|
||
Comment on attachment 695517 [details] [diff] [review]
Pass enableHighAccuracy geolocation changes to the chrome process.
[Approval Request Comment]
Bug caused by (feature/regressing bug #):
User impact if declined: Confusion and brokenness if we base b2g builds off of aurora.
Testing completed (on m-c, etc.): manual testing
Risk to taking this patch (and alternatives if risky): None.
String or UUID changes made by this patch: None.
[Approval Request Comment]
Bug caused by (feature/regressing bug #):
User impact if declined: Broken high geolocation accuracy for all content.
Testing completed: manual testing
Risk to taking this patch (and alternatives if risky): None.
String or UUID changes made by this patch: None.
Attachment #695517 -
Flags: approval-mozilla-b2g18?
Attachment #695517 -
Flags: approval-mozilla-aurora?
Assignee | ||
Comment 10•12 years ago
|
||
Backed out for suprising linux dbus crashes: https://hg.mozilla.org/integration/mozilla-inbound/rev/06c61e9f344a
https://tbpl.mozilla.org/php/getParsedLog.php?id=18311010&tree=Mozilla-Inbound
Assignee | ||
Comment 11•12 years ago
|
||
Comment 12•12 years ago
|
||
Status: NEW → RESOLVED
Closed: 12 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla20
Updated•12 years ago
|
Attachment #695517 -
Flags: approval-mozilla-b2g18?
Attachment #695517 -
Flags: approval-mozilla-b2g18+
Attachment #695517 -
Flags: approval-mozilla-aurora?
Attachment #695517 -
Flags: approval-mozilla-aurora+
Assignee | ||
Comment 13•12 years ago
|
||
https://hg.mozilla.org/releases/mozilla-aurora/rev/3a75155ac44d
https://hg.mozilla.org/releases/mozilla-b2g18/rev/d1349e9be2af
status-b2g18:
--- → fixed
status-firefox19:
--- → fixed
Assignee | ||
Comment 14•12 years ago
|
||
https://hg.mozilla.org/releases/mozilla-aurora/rev/df31048b8060
https://hg.mozilla.org/releases/mozilla-b2g18/rev/23a6717c6d3f
I landed an old version on aurora and b2g18.
Assignee | ||
Comment 15•12 years ago
|
||
Comment 16•12 years ago
|
||
Does it means bug 806219 is fixed?
You need to log in
before you can comment on or make changes to this bug.
Description
•