From a3e079ff22fee3678e142415fa0d67c670dc7bc6 Mon Sep 17 00:00:00 2001 From: Yutaka Hirano Date: Tue, 13 Jul 2021 21:18:18 +0900 Subject: [PATCH 1/5] Terminate WebTransport sessions when unloading page Fixes w3c/webtransport#127. --- source | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/source b/source index b82ce5b9fab..338dd0937cf 100644 --- a/source +++ b/source @@ -4080,6 +4080,18 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
  • process the manifest
  • + +
    WebTransport
    +
    +

    The following features are defined in WebTransport:

    + + +

    @@ -88498,6 +88510,17 @@ dictionary PageTransitionEventInit : EventInit

    Empty window's list of active timers.

    + +
  • +

    For each WebTransport object transport whose relevant global + object is window and [[State]] + is "connected", terminate transport's + [[Session]].

    + +

    This needs to be done in workers too. See + #6831.

    +
  • @@ -124968,6 +124991,9 @@ INSERT INTERFACES HERE
    [WEBMCG]
    WebM Container Guidelines. The WebM Project.
    +
    [WEBTRANSPORT]
    +
    WebTransport, Bernard Aboda, Victor Vasiliev, Yutaka Hirano. W3C.
    +
    [WEBVTT]
    WebVTT, S. Pieters. W3C.
    From cf731b97b49c931282ad2ab6b2586977fdf7d019 Mon Sep 17 00:00:00 2001 From: Yutaka Hirano Date: Tue, 13 Jul 2021 21:27:44 +0900 Subject: [PATCH 2/5] fix --- source | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source b/source index 338dd0937cf..d921e94798d 100644 --- a/source +++ b/source @@ -4088,7 +4088,7 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute @@ -88516,7 +88516,7 @@ dictionary PageTransitionEventInit : EventInit is window and [[State]] is "connected", terminate transport's - [[Session]].

    + [[Session]].

    This needs to be done in workers too. See #6831.

    From e6be10d709b29829fba9a15b9ad0cb021356e1ca Mon Sep 17 00:00:00 2001 From: Yutaka Hirano Date: Wed, 14 Jul 2021 14:27:21 +0900 Subject: [PATCH 3/5] fix --- source | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/source b/source index d921e94798d..9883076dc19 100644 --- a/source +++ b/source @@ -4087,7 +4087,7 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
    • terminate
    • -
    • [[State]]
    • +
    • [[State]]
    • [[Session]]
    • WebTransport
    @@ -88513,10 +88513,18 @@ dictionary PageTransitionEventInit : EventInit

    For each WebTransport object transport whose relevant global - object is window and [[State]] - is "connected", terminate transport's - [[Session]].

    + object is window, run these steps:

    + +
      +
    1. If transport's [[State]] is + "connected", terminate transport's + [[Session]] in parallel.

    2. + +
    3. If transport's [[State]] is + "connecting", set transport's + [[State]] to "failed".

    4. +

    This needs to be done in workers too. See #6831.

    From 7b41c98649ab029b9164b1df608f4b58ccb572ea Mon Sep 17 00:00:00 2001 From: Yutaka Hirano Date: Wed, 14 Jul 2021 14:51:49 +0900 Subject: [PATCH 4/5] fix --- source | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/source b/source index 9883076dc19..4effcc7562c 100644 --- a/source +++ b/source @@ -88497,20 +88497,6 @@ dictionary PageTransitionEventInit : EventInitsalvageable state to false.

    -
  • -

    If document's salvageable - state is false, then:

    - -
      -
    1. For each EventSource object eventSource whose relevant - global object is equal to window, forcibly close - eventSource.

    2. - -
    3. Empty window's list of active timers.

    4. -
    -
  • -
  • For each WebTransport object transport whose relevant global object is window, run these steps:

    @@ -88529,6 +88515,20 @@ dictionary PageTransitionEventInit : EventInitThis needs to be done in workers too. See #6831.

  • + +
  • +

    If document's salvageable + state is false, then:

    + +
      +
    1. For each EventSource object eventSource whose relevant + global object is equal to window, forcibly close + eventSource.

    2. + +
    3. Empty window's list of active timers.

    4. +
    +
  • From 0676e6f9d73ad38984cfb91c9e2c3b4f9f6091bf Mon Sep 17 00:00:00 2001 From: Yutaka Hirano Date: Wed, 14 Jul 2021 15:19:45 +0900 Subject: [PATCH 5/5] fix --- source | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source b/source index 4effcc7562c..a90946fa708 100644 --- a/source +++ b/source @@ -88503,7 +88503,8 @@ dictionary PageTransitionEventInit : EventInit
  • If transport's [[State]] is - "connected", "connected", set transport's + [[State]] to "failed" and terminate transport's [[Session]] in parallel.