From 8e14afe97a86651be1df7a81765d5da34fee39d6 Mon Sep 17 00:00:00 2001 From: Timothy Flynn Date: Mon, 14 Apr 2025 18:38:24 -0400 Subject: [PATCH] LibWeb: Update imported WPT utility file This changed upstream and affects our ability to import BYOB tests. See: https://github.com/web-platform-tests/wpt/commit/bc9dcbbf1a4c2c741ef47f47d6ede6458f40c4a4 --- .../input/wpt-import/streams/resources/rs-utils.js | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/Tests/LibWeb/Text/input/wpt-import/streams/resources/rs-utils.js b/Tests/LibWeb/Text/input/wpt-import/streams/resources/rs-utils.js index f52dd6197b7..0f7742a5b3b 100644 --- a/Tests/LibWeb/Text/input/wpt-import/streams/resources/rs-utils.js +++ b/Tests/LibWeb/Text/input/wpt-import/streams/resources/rs-utils.js @@ -215,15 +215,7 @@ } function transferArrayBufferView(view) { - const noopByteStream = new ReadableStream({ - type: 'bytes', - pull(c) { - c.byobRequest.respond(c.byobRequest.view.byteLength); - c.close(); - } - }); - const reader = noopByteStream.getReader({ mode: 'byob' }); - return reader.read(view).then((result) => result.value); + return structuredClone(view, { transfer: [view.buffer] }); } self.RandomPushSource = RandomPushSource;