gecko-dev/dom/geolocation
Andrew McCreight 1bf6681a43 Bug 1256061 - Hold a strong reference to a request when we call a method on it. r=jdm
I think it is possible for the TimerCallbackHolder to fire off a
Notify() while the geolocation object and the nsGeolocationRequest are
only holding each other alive, so they would be freed by the cycle
collector the next time it runs, but we haven't run the cycle
collector yet. If that happens, then Geolocation::RemoveRequest()
would break the cycle, causing stuff to unravel and bad things to
happen. To fix this, we just hold the request alive in
TimerCallbackHolder::Notify(), which will also ensure that the
geolocation object is alive, hopefully preventing crashes.

This will make the Notify() behavior similar to what it was before bug
1238427, when the nsITimer object would hold a strong reference to the
request when the Notify() was being run.
2016-03-23 12:59:14 -07:00
..
MLSFallback.cpp
MLSFallback.h
moz.build
nsGeoGridFuzzer.cpp
nsGeoGridFuzzer.h
nsGeoPosition.cpp
nsGeoPosition.h
nsGeoPositionIPCSerialiser.h
nsGeolocation.cpp Bug 1256061 - Hold a strong reference to a request when we call a method on it. r=jdm 2016-03-23 12:59:14 -07:00
nsGeolocation.h
nsGeolocationSettings.cpp Bug 1254847 part 3. Make AutoEntryScript always take ownership of error reporting. r=bholley 2016-03-09 19:02:03 -05:00
nsGeolocationSettings.h