Bug 1504464 - Part 8: Rename the handler called when a tee'd stream becomes errored. r=jwalden

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

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Jason Orendorff 2019-01-14 20:35:12 +00:00
parent 7f84bdfbb1
commit b1a621b618

View File

@ -1192,7 +1192,7 @@ static MOZ_MUST_USE bool ReadableStreamControllerError(
* Streams spec, 3.3.9. step 18:
* Upon rejection of reader.[[closedPromise]] with reason r,
*/
static bool TeeReaderClosedHandler(JSContext* cx, unsigned argc, Value* vp) {
static bool TeeReaderErroredHandler(JSContext* cx, unsigned argc, Value* vp) {
CallArgs args = CallArgsFromVp(argc, vp);
Rooted<TeeState*> teeState(cx, TargetFromHandler<TeeState>(args));
HandleValue reason = args.get(0);
@ -1303,7 +1303,8 @@ static MOZ_MUST_USE bool ReadableStreamTee(
// Step 18: Upon rejection of reader.[[closedPromise]] with reason r, [...]
RootedObject closedPromise(cx, reader->closedPromise());
RootedObject onRejected(cx, NewHandler(cx, TeeReaderClosedHandler, teeState));
RootedObject onRejected(cx,
NewHandler(cx, TeeReaderErroredHandler, teeState));
if (!onRejected) {
return false;
}