From 330f04b76fd8cbfbdc496e3c19a85d9b49746aca Mon Sep 17 00:00:00 2001 From: Joey Parrish Date: Wed, 26 Apr 2023 22:24:02 -0700 Subject: [PATCH] fix: Fix HEAD request exception (#5194) We should not look for response data in a HEAD request. Fixes #5164 --- lib/net/networking_engine.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/net/networking_engine.js b/lib/net/networking_engine.js index c09fdb9405..ae80edb6a5 100644 --- a/lib/net/networking_engine.js +++ b/lib/net/networking_engine.js @@ -320,6 +320,7 @@ shaka.net.NetworkingEngine = class extends shaka.util.FakeEventTarget { if (!responseAndGotProgress.gotProgress && this.onProgressUpdated_ && !response.fromCache && + request.method != 'HEAD' && type == shaka.net.NetworkingEngine.RequestType.SEGMENT) { this.onProgressUpdated_(response.timeMs, response.data.byteLength); }