Commit Graph

2285 Commits

Author SHA1 Message Date
Nicholas Nethercote
0af735c7d5 Bug 1186810 (part 1) - Replace nsBaseHashtable::EnumerateRead() calls in dom/workers/ with iterators. r=nsm.
--HG--
extra : rebase_source : ecb25ba6577e77b38894b117893545640de013e2
2015-10-25 21:08:54 -07:00
Ben Kelly
69c8a55480 Bug 1215140 P10 Avoid AddRef'ing the nsIChannel OMT. r=bz 2015-10-29 19:53:25 -07:00
Ben Kelly
e3bee41820 Bug 1215140 P9 Provide file and line number when FetchEvent.preventDefault() cancels a request. r=bz
* * *
Bug 1215140 P9 interdiff 001
2015-10-29 19:53:25 -07:00
Ben Kelly
b9615b724e Bug 1215140 P6 Update service worker interception error strings to include detailed parameters. r=bz 2015-10-29 19:53:25 -07:00
Ben Kelly
5fb3550c91 Bug 1215140 P5 Report the line number where respondWith() was called. r=bz 2015-10-29 19:53:25 -07:00
Ben Kelly
f55ae9b765 Bug 1215140 P4 Make service worker respondWith() use channel ConsoleReportCollector. r=bz 2015-10-29 19:53:25 -07:00
Catalin Badea
e13c1c9c9e Bug 1172870 - Part 3 - Fix openWindow mochitest to work on e10s. r=smaug 2015-10-30 01:30:58 +02:00
Catalin Badea
8255b13467 Bug 1172870 - Part 2 - Enable ServiceWorkerClients::OpenWindow on e10s desktop. r=smaug 2015-10-30 01:30:57 +02:00
Ehsan Akhgari
da8340a541 Bug 1218621 - Keep the service worker alive while the promise passed to FetchEvent.respondWith() settles; r=catalinb 2015-10-27 17:10:57 -04:00
Ehsan Akhgari
073195c513 Bug 1206298 - Part 2: Add a test to make sure that we respect Cache-Control headers on the synthesized response; r=jdm 2015-10-27 11:58:30 -04:00
Ehsan Akhgari
8bb8104d86 Bug 1218499 - Make FetchEvent.request nullable; r=bzbarsky 2015-10-26 23:00:19 -04:00
Ehsan Akhgari
6a86907c4e Bug 1218151 - Make FetchEventInit.isReload default to false; r=bzbarsky 2015-10-26 23:00:17 -04:00
Ehsan Akhgari
7029e804f8 Bug 1218135 - Remove FetchEvent.client; r=bzbarsky
This has been removed from the spec.  See:
https://github.com/slightlyoff/ServiceWorker/issues/723#issuecomment-123516555
2015-10-26 23:00:16 -04:00
Ehsan Akhgari
61cf88b565 Bug 1214772 - Part 2: Make FetchEvent inherit from ExtendableEvent; r=bzbarsky 2015-10-26 23:00:14 -04:00
Ehsan Akhgari
b17439be5e Bug 1214772 - Part 1: Move the declaration of FetchEvent to after that of ExtendableEvent; r=bkelly 2015-10-26 23:00:13 -04:00
Ehsan Akhgari
28e742e312 Bug 1218146 - Move WindowClient.frameType to Client.frameType; r=bzbarsky 2015-10-26 16:00:00 -04:00
Ehsan Akhgari
c41762a46d Bug 1218142 - Remove ServiceWorkerGlobalScope.onbeforeevicted/onevicted; r=bzbarsky 2015-10-26 15:59:58 -04:00
Ehsan Akhgari
14fbafb7be Bug 1218139 - Remove ServiceWorkerContainer.onreloadpage; r=bzbarsky 2015-10-26 15:59:57 -04:00
Ehsan Akhgari
c43ad45f05 Bug 1218119 - Simplify defining worker prefs; r=baku 2015-10-26 14:06:28 -04:00
Andrea Marchesini
24cd451d65 Bug 1211967 - Fix how we report errors when loading a worker from a data url, r=bz 2015-10-26 17:28:45 +00:00
Ehsan Akhgari
e2a80ec087 Bug 1189685 - Part 1: Ensure that the state of all ServiceWorker instances is up to date when dispatching statechange events; r=bkelly 2015-10-26 12:37:48 -04:00
Ehsan Akhgari
5273912012 Bug 1202001 - Log errors emitted during service worker lifecycle events to the Web Console; r=bkelly 2015-10-26 12:30:46 -04:00
Ehsan Akhgari
80c460d668 Bug 1181054 - Part 3: Correctly handle upload channels that have embedded body headers when dispatching a FetchEvent; r=bkelly 2015-10-26 12:21:03 -04:00
Carsten "Tomcat" Book
3f4ea95cfa Merge m-c to mozilla-inbound 2015-10-26 11:29:00 +01:00
Carsten "Tomcat" Book
758c43af6b merge mozilla-inbound to mozilla-central a=merge 2015-10-26 10:57:35 +01:00
dimi
975b82b179 Bug 1207727 - Add WPT tests for service worker update algorithm. r=bkelly 2015-10-26 11:03:47 +08:00
dimi
0a7f5412e3 Bug 1207727 - Rework updating service workers according to the latest spec. r=bkelly 2015-10-26 10:59:48 +08:00
Victor Porof
9dc0ce6b1a Bug 1202657 - Add markers for workers' message passing and serialization/deserialization, r=smaug, jsantell, tromey, ejpbruel
--HG--
rename : docshell/base/timeline/OTMTMarkerReceiver.h => docshell/base/timeline/MarkersStorage.h
2015-10-21 23:10:05 +02:00
Olli Pettay
a062f00aab Bug 1218190 - Add a pref to enable Clients.openWindow, r=catalinb 2015-10-25 22:36:27 +02:00
Ryan VanderMeulen
4e1540b2b5 Bug 779707 - Add crashtest. 2015-10-25 00:06:24 -04:00
Catalin Badea
cc62c14549 Bug 1172870 - Implement service workers clients.openWindow for desktop (non-e10s). r=baku,smaug
Based on patches from:
  Nikhil Marathe <nsm.nikhil@gmail.com>
  Alberto Crespell Perez <alberto.crespell@gmail.com>
2015-10-24 15:16:23 +03:00
Ehsan Akhgari
bbf58e7a30 Bug 1185558 - Send a "Service-Worker: script" header when downloading service worker scripts; r=bkelly 2015-10-22 17:33:35 -04:00
Ben Kelly
c0ad7f1171 Bug 1212904 P7 Verify xhr respects service worker CORS tainting. r=ehsan 2015-10-22 11:07:32 -07:00
Ben Kelly
d7e898d8d0 Bug 1212904 P4 Set channel tainting in FetchEvent.respondWith(). r=ehsan 2015-10-22 11:07:32 -07:00
Josh Matthews
d3726427db Bug 1173811 - Part 1: Propagate the response URL to intercepted channels when necessary (non-e10s). r=mayhemer,bkelly 2015-10-22 09:23:39 -04:00
Ehsan Akhgari
383397be38 Bug 1216697 - Unship Request.cache until the implementation is finished; r=bzbarsky 2015-10-23 15:38:47 -04:00
Tooru Fujisawa
24ab66bc98 Bug 1217093 - Remove for-each from dom/. r=smaug
--HG--
extra : commitid : DcjxshJqlKg
extra : rebase_source : 23bc9a985f1e6d13e13837e31bb9b88b9be24d55
2015-10-19 02:00:50 +09:00
Phil Ringnalda
6401c0185c Back out 2 changesets (bug 1173811) for test_synthesized_response.js timeouts
CLOSED TREE

Backed out changeset 56bc1314e660 (bug 1173811)
Backed out changeset 0ad51d302ba9 (bug 1173811)
2015-10-21 20:21:05 -07:00
Josh Matthews
591281df75 Bug 1173811 - Part 1: Propagate the response URL to intercepted channels when necessary (non-e10s). r=mayhemer,bkelly 2015-10-21 00:05:40 -04:00
Ehsan Akhgari
8ab0d9d2f8 Bug 931243 - Remove the XMLHttpRequest APIs from ServiceWorkerGlobalScope; r=bzbarsky 2015-10-20 13:16:34 -04:00
Ehsan Akhgari
9d5b088d22 Bug 1189673 - Set FetchEvent.request.headers' guard to immutable before dispatching the FetchEvent; r=bkelly 2015-10-20 10:21:11 -04:00
Nigel Babu
7cb4a2efa8 Backed out changeset 4b38a09cca56 (bug 1189673) for W(4) and W(8) bustages ON A CLOSED TREE 2015-10-20 13:52:22 +05:30
Ehsan Akhgari
34f6acee2f Bug 1189673 - Set FetchEvent.request.headers' guard to immutable before dispatching the FetchEvent; r=bkelly 2015-10-19 21:54:38 -04:00
Jonas Sicking
7bf7cbbd1a Bug 1215746: Remove RequestMode::Cors_with_forced_preflight. r=bkelly 2015-10-19 18:24:36 -07:00
Jonas Sicking
cc10dd7ad3 Bug 1182571: Make nsXMLHttpRequest use AsyncOpen2. r=ehsan 2015-10-19 11:14:54 -07:00
Ehsan Akhgari
ca6a03d7a4 Bug 1198397 - Add a test for interception of requests upgraded through the CSP upgrade-insecure-requests directive; r=jdm 2015-10-19 11:17:10 -04:00
Ehsan Akhgari
6673eddd94 Bug 1198394 - Part 2: Add a test for interception of HSTS upgraded connections; r=jdm 2015-10-19 10:32:38 -04:00
Christoph Kerschbaumer
643f27c257 Bug 1208559 - Hook up ServicerWorkers with CSP (r=sicking,bkelly,dveditz) 2015-10-18 19:59:18 -07:00
Bobby Holley
cd781ec71f Bug 1208559 - Do a CSP Check in ServiceWorkerManager::Register (r=ckerschb) 2015-10-18 19:38:06 -07:00
Nathan Froyd
01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
Ehsan Akhgari
9dd6f325b3 Bug 1215601 - Enable service workers for non-release builds on Fennec similar to desktop; r=bkelly 2015-10-16 14:08:08 -04:00
Eddy Bruel
f7c6589364 Bug 1178726 - Simplify how we deal with freezing/thawing workers;r=jlongster,khuey 2015-10-16 18:48:26 +02:00
Ehsan Akhgari
73e2c128c6 Bug 1215230 - Disable service workers and push notifications on non-release builds until we're ready to ship them; r=bkelly 2015-10-16 11:19:57 -04:00
Wes Kocher
c2b3d9275b Backed out 2 changesets (bug 1182571) for being a likely cause of the Android S4 errors
Backed out changeset e2b3064dcace (bug 1182571)
Backed out changeset 8153ae231d16 (bug 1182571)
2015-10-15 14:07:06 -07:00
Jonas Sicking
2578b19458 Bug 1182571: Make nsXMLHttpRequest use AsyncOpen2. r=ehsan 2015-10-15 12:18:21 -07:00
Andrea Marchesini
f93604eafb Bug 1211970 - "Muted errors in workers are not correctly reported to the console". r=bz 2015-10-15 05:05:00 +02:00
Andrea Marchesini
ef38daea39 Bug 1160890, r=smaug 2015-10-15 14:06:55 +02:00
Andrea Marchesini
0d7595b59b Bug 1214300 - AsyncErrorReporter doesn't use JSRuntime param., r=smaug 2015-10-14 11:29:55 +01:00
Morris Tseng
d1d37e3f9b Bug 709490 - Part 10: Using mechanism in RuntimeService to get pref in worker thread instead of gfxPref. r=baku
--HG--
extra : rebase_source : 55ae1e1fc1f88bffd43800eefaed4506789e608c
2015-10-12 11:21:04 +08:00
Morris Tseng
c3d37560cc Bug 709490 - Part 5: Add interfaces test. r=ehsan
--HG--
extra : rebase_source : d5cca4941baf9c5e3fbe05cb7f4d12d860ef1825
2015-10-12 11:21:03 +08:00
Ehsan Akhgari
ac53f535f2 Bug 1179397 - Disallow FetchEvent.respondWith() when the dispatch flag is unset; r=jdm 2015-10-09 13:36:53 -04:00
Ehsan Akhgari
1869e89340 Bug 1212636 - Add a better error message for the content corrupcted error caused by the Promise being passed to FetchEvent.respondWith; r=bkelly 2015-10-07 18:06:26 -04:00
Bill McCloskey
1b6da7ed71 Back out bug 967873 - Test changes for async removeTab 2015-10-07 11:15:11 -07:00
Andrew McCreight
0ff7248107 Bug 1210517 - Create nsVariant directly rather than via do_CreateInstance(). r=froydnj
The goal here is to leave creation stuff mostly for JS, so we can
convert it entirely over to a non-threadsafe cycle-collected version
without breaking any existing C++ users.

I didn't do this for a remaining use in nsGlobalWindow.h to avoid
including nsVariant.h all over the place.
2015-10-07 08:17:42 -07:00
Carsten "Tomcat" Book
08997000eb Backed out 2 changesets (bug 1202902) to recking bug 1202902 to be able to reopen inbound on a CLOSED TREE
Backed out changeset 647025383676 (bug 1202902)
Backed out changeset d70c7fe532c6 (bug 1202902)
2015-10-07 14:03:21 +02:00
Eddy Bruel
41c0e5355c Bug 1178721 - Implement SuspendWorkersForWindow;r=khuey 2015-10-07 12:20:59 +02:00
Carsten "Tomcat" Book
e7ef778c9d Backed out 1 changesets (bug 1202902) for causing merge conflicts to mozilla-central
Backed out changeset cfc1820361f5 (bug 1202902)

--HG--
extra : rebase_source : 5d3db72337754bc7ab0ed0c30b2896100411ff92
2015-10-07 12:13:45 +02:00
Shu-yu Guo
d06b6030f6 Bug 1202902 - Scripted fix the world. 2015-10-06 14:00:31 -07:00
Ben Kelly
323efab6af Bug 1210941 P11 Use LOAD_BYPASS_SERVICE_WORKER in worker ScriptLoader. r=ehsan 2015-10-06 06:37:07 -07:00
Ben Kelly
fd3893120c Bug 1210941 P7 Use LOAD_BYPASS_SERVICE_WORKER in ServiceWorkerScriptCache. r=ehsan 2015-10-06 06:37:07 -07:00
Ehsan Akhgari
d826574ea3 Bug 1179401 - Call stopImmediatePropagation() on the Event object in respondWith(); r=jdm 2015-10-05 16:12:28 -04:00
Wes Kocher
0628e22f00 Merge m-c to inbound, a=merge CLOSED TREE 2015-10-05 13:11:26 -07:00
Wes Kocher
7492fb02ac Merge inbound to central, a=merge 2015-10-05 13:02:21 -07:00
Andrew McCreight
5171450b27 Bug 1197893 - Check the number of arguments for ThrowTypeError() and ThrowRangeError() at compile time. r=peterv 2015-10-05 09:38:14 -07:00
Wes Kocher
c1750b75c7 Backed out 11 changesets (bug 709490) for webgl-color-test.html failures a=backout
Backed out changeset fc04c5d43550 (bug 709490)
Backed out changeset cd8f9410d335 (bug 709490)
Backed out changeset 6e687c9143c1 (bug 709490)
Backed out changeset 9b20f2c833c4 (bug 709490)
Backed out changeset f9d130aea88e (bug 709490)
Backed out changeset fc513b410949 (bug 709490)
Backed out changeset acf6220b431a (bug 709490)
Backed out changeset 9bceaf913791 (bug 709490)
Backed out changeset 37fba20111e2 (bug 709490)
Backed out changeset 2285ce1596b8 (bug 709490)
Backed out changeset fb4e09920569 (bug 709490)
2015-10-05 08:28:25 -07:00
Nick Fitzgerald
ee543a3018 Bug 1209263 - Allow embedders to tell SpiderMonkey how to structured clone principals; r=bz
--HG--
extra : rebase_source : 04835c034431953344e83203e7753043461474ba
2015-10-02 16:44:00 +02:00
Nicholas Nethercote
77d38112ab Bug 1209351 (part 2) - Optimize nsTHashTable::RemoveEntry() usage in dom/. r=bz.
--HG--
extra : rebase_source : 8550f181356550b6c0e540c12f61f2d1148d2050
2015-09-24 19:05:16 -07:00
Morris Tseng
f5a52e7dea Bug 709490 - Part 10: Using mechanism in RuntimeService to get pref in worker thread instead of gfxPref. r=baku
--HG--
extra : rebase_source : 07b470b9a8865b7d833932c5425e796b852ab466
2015-10-05 10:50:17 +08:00
Morris Tseng
0b16df6ac0 Bug 709490 - Part 5: Add interfaces test. r=ehsan
--HG--
extra : rebase_source : 306df6c0c7fe3e09e199b5c7b5cd62974b2854c3
2015-10-05 10:50:16 +08:00
Wes Kocher
f0d829220d Backed out changeset 821791826960 (bug 1197893) for Nexus build failures CLOSED TREE 2015-10-02 16:17:05 -07:00
Andrew McCreight
35cd15b8de Bug 1197893 - Check the number of arguments for ThrowTypeError() and ThrowRangeError() at compile time. r=peterv 2015-10-02 15:09:02 -07:00
Andrew McCreight
7a2c6267d4 Backed out changeset 6fa9cdf4002b for breaking the build. 2015-10-02 10:49:28 -07:00
Andrew McCreight
404740a102 Bug 1197893 - Check the number of arguments for ThrowTypeError() and ThrowRangeError() at compile time. r=peterv 2015-10-02 10:42:08 -07:00
Carsten "Tomcat" Book
e91d5a31b6 Merge m-c to mozilla-inbound 2015-10-02 13:37:27 +02:00
Carsten "Tomcat" Book
ca77b70a8d merge mozilla-inbound to mozilla-central a=merge 2015-10-02 11:52:49 +02:00
Ehsan Akhgari
2430b7dcee Bug 1204596 - Part 3: Store the responses with manual redirect in the tests added for bug 1164397; r=bkelly
This needs to be done so that we match the manual redirect mode
for navigations when the response is stored in the cache.
2015-10-01 18:47:07 -04:00
Yoshi Huang
f97211a451 Bug 1167100 - User originAttribute in ContentPrincipalInfo. r=bholley 2015-09-23 18:19:06 +08:00
Catalin Badea
4fa36e326a Bug 1188545 - Disable unstable test: test_aboutserviceworkers.html. a=testonly 2015-09-30 19:11:04 -04:00
Catalin Badea
24a19b6a02 Bug 1188545 - Cancel network interceptions when the service worker is being terminated with unresolved respondWith promises. r=nsm 2015-09-30 19:11:03 -04:00
Catalin Badea
450ddec732 Bug 1188545 - Add tests for service workers' lifetime management. r=nsm 2015-09-30 19:11:03 -04:00
Catalin Badea
1049eff81c Bug 1188545 - Prevent service workers from being terminated while checking if the script evaluation was successful. r=nsm 2015-09-30 19:11:03 -04:00
Catalin Badea
cce3b797b1 Bug 1188545 - respondWith promise should extend the service worker's lifetime. r=nsm 2015-09-30 19:11:03 -04:00
Catalin Badea
518e55a5ed Bug 1188545 - Terminate service workers that have been idle for some time. r=nsm 2015-09-30 19:11:03 -04:00
Catalin Badea
294f7838e4 Bug 1188545 - Cosmetic changes regarding workerPrivate properties shared between shared workers and service workers. r=nsm 2015-09-30 19:11:03 -04:00
Catalin Badea
c5f9033d16 Bug 1188545 - ServiceWorkerRegistrationInfo::Clear() should terminated workers. r=nsm 2015-09-30 19:11:03 -04:00
Catalin Badea
76c7d43fd9 Bug 1188545 - Disentangle service workers from shared workers and refactor event dispatching code into a separate class. r=nsm,mrbkap 2015-09-30 19:11:03 -04:00
Wes Kocher
6fbdec2422 Backed out 12 changesets (bug 1188545) for test_fetch_cors failures CLOSED TREE
Backed out changeset e04738ee72a3 (bug 1188545)
Backed out changeset 1989893b59de (bug 1188545)
Backed out changeset 11ff29cc25d8 (bug 1188545)
Backed out changeset 4b6bdf859845 (bug 1188545)
Backed out changeset 76eb7ffeca2a (bug 1188545)
Backed out changeset 4473e036b52e (bug 1188545)
Backed out changeset 2a28cb794b23 (bug 1188545)
Backed out changeset 1fa2f55727f3 (bug 1188545)
Backed out changeset 032f4c24fc34 (bug 1188545)
Backed out changeset 4be675dc1b37 (bug 1188545)
Backed out changeset d5d05def5b17 (bug 1188545)
Backed out changeset e94f12b0bcf3 (bug 1188545)
2015-09-30 11:11:47 -07:00
Bill McCloskey
633d4a3ecf Bug 967873 - Test changes for async removeTab (r=Gijs) 2015-10-01 21:18:05 -07:00
Jason Orendorff
deb2270515 Bug 1054756, part 5 - Remove Class::convert.
--HG--
extra : commitid : 6KCxWrCseSZ
extra : rebase_source : 63f3cd6ec1ade43c732ffd9b661fe6f2dca9eb4b
2015-03-20 16:28:59 -05:00
Jason Orendorff
abd42d3ec5 Bug 1054756, part 3 - Implement Symbol.toPrimitive. Replace existing convert hooks with methods. r=jandem.
JSClass::convert is no longer used after this, but to minimize the noise, it will be deleted in a separate patch. However all non-nullptr convert hook implementations must be replaced with [@@toPrimitive] methods in this patch to avoid changing the behavior.

The changes in XrayWrapper.cpp fix a pre-existing bug: when an Xray wrapper tries to emit the "Silently denied access" warning, if id is a symbol, the existing code triggers an error trying to convert it to a string for the warning message. Implementing Symbol.toPrimitive revealed this bug; the fix is straightforward.

--HG--
extra : commitid : B48u39i6pxl
extra : rebase_source : bddefbd7bc131007303a5a00dd9c0bb8fec1b122
2015-03-20 14:02:55 -05:00