Граф коммитов

63 Коммитов

Автор SHA1 Сообщение Дата
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Andrea Marchesini ebf242be0d Bug 1500879 - Fetch should not consume Request/Response with null-body, r=asuth
The fetch spec treats null bodies specially.  Their Body cannot become
disturbed or locked and a fresh empty ReadableStream is returned whenever an
attempt is made to consume the body.  We currently fail a number of WPT tests
in this area because we do mark the body consumed as exposed via bodyUsed.
2018-11-06 14:48:07 +01:00
Till Schneidereit ext:(%2C%20Jason%20Orendorff%20%3Cjorendorff%40mozilla.com%3E) 2cfba34b8d Bug 1385890 - Fix Streams implementation in multiple-global uses. r=baku,tcampbell,jorendorff
Streams have multiple parts that can be JS objects from different compartments.
For example, the [[reader]] internal slot of a stream can point to a reader
object in another compartment.

This patch makes the ReadableStream implementation robust against mixing and
matching stream-related objects and methods from different globals.

This also removes ReadableStreamBYOBReader and ReadableStreamBYOBRequest for
now, with a view toward enabling basic ReadableStream features by default in
bug 1389628.

Differential Revision: https://phabricator.services.mozilla.com/D8450

--HG--
extra : rebase_source : 71d73bed5bc82557efcb6b1ecb231275fd3e1189
extra : amend_source : de29f663b9929eb2858b23cc6f4e7ba97b23a28c
extra : source : f91eb962df6a06d5f51ad13caa2a4a9c2947f293
2018-10-11 14:18:43 -05:00
Thomas Wisniewski d23454328e Bug 1491504 - shortcut blob responses from XHR and fetch when the URL is a blob URL; r=baku
shortcut blob responses from XHR and fetch when the URL is a blob URL

Differential Revision: https://phabricator.services.mozilla.com/D7253

--HG--
extra : moz-landing-system : lando
2018-10-06 17:34:24 +00:00
Ciure Andrei 47efccbbca Backed out changeset c5ac0cb25238 (bug 1491504) for FetchConsumer.cpp build bustages CLOSED TREE 2018-10-06 02:58:44 +03:00
Thomas Wisniewski 2294c78986 Bug 1491504 - shortcut blob responses from XHR and fetch when the URL is a blob URL; r=baku
shortcut blob responses from XHR and fetch when the URL is a blob URL

Differential Revision: https://phabricator.services.mozilla.com/D7253

--HG--
extra : moz-landing-system : lando
2018-10-05 20:23:55 +00:00
Thomas Wisniewski 400093bdb6 Bug 1482752 - Have Fetch bodies use File blobs for local files instead of regular blobs. r=baku
Have Fetch bodies use File blobs for local files instead of regular blobs.

Differential Revision: https://phabricator.services.mozilla.com/D3183

--HG--
extra : moz-landing-system : lando
2018-09-11 19:13:15 +00:00
Cosmin Sabou dc72962df3 Backed out changeset 68805212630a (bug 1482752) for causing build bustages on dom/fetch. CLOSED TREE 2018-09-08 20:46:04 +03:00
Thomas Wisniewski 4d92a94c0d Bug 1482752 - Have Fetch bodies use File blobs for local files instead of regular blobs. r=baku
Have Fetch bodies use File blobs for local files instead of regular blobs.

Differential Revision: https://phabricator.services.mozilla.com/D3183

--HG--
extra : moz-landing-system : lando
2018-09-08 14:34:37 +00:00
Andrea Marchesini e1a0b51543 Bug 1478101 - Split AbortSignal in 2 classes: AbortSignal and AbortSignalImpl, r=bz 2018-08-26 14:16:21 +02:00
Andrea Marchesini f46c7858b5 Bug 1446204 - Response body should be marked as used if used as stream, r=till 2018-03-16 16:52:28 +01:00
Andrea Marchesini 2c7c69af24 Bug 1432963 - Fixing workers headers - part 14 - WorkerPrivate without workers namespace, r=smaug 2018-01-31 08:24:08 +01:00
Andrea Marchesini 76ea37870c Bug 1390717 - FetchStream should not have an extra JS::Heap<ReadableStream>, r=jonco 2017-08-31 16:29:02 +02:00
Andrea Marchesini 3e5de60a22 Bug 1378342 - AbortSignal/AbortController - part 9 - Request.signal should not be a reference of RequestInit.signal, r=bkelly 2017-08-29 11:31:07 +02:00
Andrea Marchesini a441d6f43c Bug 1378342 - AbortSignal/AbortController - part 8 - Aborting ReadableStream when AbortSignal is aborted, r=bkelly 2017-08-29 11:31:06 +02:00
Andrea Marchesini f533937740 Bug 1378342 - AbortSignal/AbortController - part 6 - Implement Request.signal, r=bkelly 2017-08-29 11:31:06 +02:00
Sebastian Hengst 80e618e605 Backed out changeset 2c6f49d73935 (bug 1378342) 2017-08-29 09:16:59 +02:00
Sebastian Hengst 03d1665672 Backed out changeset 64d0dbf9706b (bug 1378342) 2017-08-29 09:16:48 +02:00
Sebastian Hengst db728bce54 Backed out changeset 4c41e61d6763 (bug 1378342) 2017-08-29 09:16:43 +02:00
Andrea Marchesini b89d4f379a Bug 1378342 - AbortSignal/AbortController - part 9 - Request.signal should not be a reference of RequestInit.signal, r=bkelly 2017-08-29 07:30:21 +02:00
Andrea Marchesini 268b173378 Bug 1378342 - AbortSignal/AbortController - part 8 - Aborting ReadableStream when AbortSignal is aborted, r=bkelly 2017-08-29 07:30:21 +02:00
Andrea Marchesini afa1c0c6c4 Bug 1378342 - AbortSignal/AbortController - part 6 - Implement Request.signal, r=bkelly 2017-08-29 07:30:21 +02:00
Andrea Marchesini 6e330b0360 Bug 1128959 - Implement the WHATWG Streams spec - part 16 - report stream errors during consumption r=bkelly 2017-08-10 18:04:56 -07:00
Andrea Marchesini cb3c4dda07 Bug 1128959 - Implement the WHATWG Streams spec - part 12 - starting body consuming and passing the JSContext down from the binding entrypoints to where the ReadableStream could be read, r=bz
This patch does 2 things:

. when SetBodyUsed() is called, the pump for the stream reading is activated.

. Just because of the reading of the stream could end up executing JS code, we
  need to pass the JSContext in the correct state down to SetBodyUsed.
2017-08-10 18:04:55 -07:00
Andrea Marchesini e44cd2d765 Bug 1128959 - Implement the WHATWG Streams spec - part 9 - FetchStreamReader, r=bkelly 2017-08-10 18:04:55 -07:00
Andrea Marchesini 3a14f6c21f Bug 1128959 - Implement the WHATWG Streams spec - part 7 - Response.body, r=bkelly 2017-08-10 18:04:55 -07:00
Andrea Marchesini 3b86092f16 Bug 1128959 - Implement the WHATWG Streams spec - part 4 - Fetch implementation, r=bkelly 2017-08-10 18:04:54 -07:00
Andrea Marchesini 99819a81c8 Bug 1128959 - Implement the WHATWG Streams spec - part 2 - Use of ReadableStream in WebIDL files, r=bkelly 2017-08-10 18:04:54 -07:00
Andrea Marchesini 4b75cfc9bc Bug 1373555 - Move the Fetch consume body login in a separate class - part 3 - Move the consuming body logic from FetchBody to FetchBodyConsumer, r=bkelly 2017-06-20 17:53:21 +02:00
Andrea Marchesini 50e54e6b44 Bug 1373555 - Move the Fetch consume body login in a separate class - part 2 - Rename FetchBodyWrapper to FetchBodyConsumer, r=bkelly 2017-06-20 17:53:21 +02:00
Andrea Marchesini e768233bc4 Bug 1371889 - Fetch body must be kept alive using refcounting, r=bkelly 2017-06-20 17:53:20 +02:00
Bevis Tseng 024ff96b5b Bug 1363318 - Part 2: Label FetchBody. r=baku 2017-05-16 18:12:24 +08:00
Andrea Marchesini 4434f5a668 Bug 1337722 - Use BufferSource in webIDL, r=qdot 2017-02-09 10:37:54 +01:00
Boris Zbarsky 1f816c60cf Bug 1335368 part 12. Remove the use of IsCallerChrome in FetchRequest. r=bkelly 2017-02-01 15:43:37 -05:00
Andrea Marchesini 50b8aabe39 Bug 1312410 - Fetch API should use MutableBlobStorage to store big Blobs on disk, r=qdot 2016-10-26 09:07:25 +02:00
Andrea Marchesini aac2306f2c Bug 1269154 - Get rid of WorkerFeature: WorkerHolder, r=khuey
--HG--
rename : dom/cache/Feature.cpp => dom/cache/CacheWorkerHolder.cpp
rename : dom/cache/Feature.h => dom/cache/CacheWorkerHolder.h
rename : dom/workers/WorkerFeature.h => dom/workers/WorkerHolder.h
2016-06-23 10:53:14 +02:00
Carsten "Tomcat" Book 47aeb86e2c Backed out changeset 1c5d78c7ba43 (bug 1269154) for bustage on a CLOSED TREE
--HG--
rename : dom/cache/CacheWorkerHolder.cpp => dom/cache/Feature.cpp
rename : dom/cache/CacheWorkerHolder.h => dom/cache/Feature.h
rename : dom/workers/WorkerHolder.h => dom/workers/WorkerFeature.h
extra : rebase_source : 49f9e9ce0500ac441fe97878cf9308804926544f
2016-06-23 10:13:54 +02:00
Andrea Marchesini 45087a7970 Bug 1269154 - Get rid of WorkerFeature: WorkerHolder, r=khuey
--HG--
rename : dom/cache/Feature.cpp => dom/cache/CacheWorkerHolder.cpp
rename : dom/cache/Feature.h => dom/cache/CacheWorkerHolder.h
rename : dom/workers/WorkerFeature.h => dom/workers/WorkerHolder.h
2016-06-22 17:24:35 +02:00
Jonathan Watt b15368cfcb Bug 1279451 - Remove a lot of unnecessary includes of nsAutoPtr.h. rs=sparky 2016-06-07 21:10:18 +01:00
Jonas Sicking 32162d33c2 Bug 1273279 - Changes in preparation for FlyWeb landing. Change InternalResponse handling to track body size. r=baku f=bkelly
--HG--
extra : amend_source : 257331b8f4b86d6e1c7608ca6866526ce6aa645a
2016-06-01 17:02:29 -04:00
Jonathan Watt a73bd8c354 Bug 1253094, part 1 - Stop using DebugOnly for class/struct members in dom/. r=baku
MozReview-Commit-ID: ErWZs9oV4WS
2016-02-26 15:52:06 +00: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
Andrew McCreight 9e8f4b219e Bug 1152551, part 2 - Fix mode lines in dom/. r=jst 2015-05-03 15:32:37 -04:00
Andrea Marchesini 789ad8312d Bug 1156632 - Remove unused forward class declarations - patch 3 - dom/{events,xbl,xslt,xul} and others, r=ehsan 2015-04-22 08:29:18 +02:00
Nikhil Marathe c9908ee8be Bug 1109751 - Request and Response constructors should set mime type. r=baku
--HG--
extra : rebase_source : 8efaf2edd3f3c5d1cd7c49615ac735805a4f4e84
2015-02-03 12:59:32 -08:00
Nikhil Marathe 9b5f6b134f Bug 1109751 - Consume FormData support in Fetch API. r=baku
--HG--
extra : __touch-noise__ : 2181078256
extra : transplant_source : %A4%7F%FF%9CV%9F%2C%F7%C1%A0%BBoc%CC%BB%0E%8E%F5%80%C1
2015-04-03 22:55:15 -07:00
Wes Kocher e73d6e8c9e Backed out 2 changesets (bug 1109751) for asan mochitest-3 failures
Backed out changeset 269ce19afa43 (bug 1109751)
Backed out changeset add6d1bd2e52 (bug 1109751)
2015-04-03 12:22:47 -07:00
Nikhil Marathe 403581f769 Bug 1109751 - Request and Response constructors should set mime type. r=baku
--HG--
extra : transplant_source : %F3%C3Z%D1%E4%ABTte%80%0D%F5%A9%9AI%B5J%A8W%24
extra : histedit_source : 33c98443b879f7d29fff3e98b640a22c77f462c6
2015-02-03 12:59:32 -08:00
Nikhil Marathe dd5c91927a Bug 1109751 - Consume FormData support in Fetch API. r=baku
--HG--
extra : transplant_source : %B0%0F%AB%E9%DBV%D1%86%980%28L%EC%CBI%0A%09%26%FDS
extra : histedit_source : 39fe8278cf135aa63a59ef4024432fab9ce5c7ee
2015-04-02 10:51:13 -07:00
Nikhil Marathe ac84e104df Bug 1143857 - Add FormData serialize support to Fetch API. r=ehsan
--HG--
extra : rebase_source : e971be3409e5c8de982e8ffcfcc87dcebb4c3867
2015-03-17 08:32:04 -07:00