Skip to content

Commit 6afd3ba

Browse files
committed
remove query params from URLs when caching their bytecode
1 parent 5ffa7c9 commit 6afd3ba

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

Source/WebCore/bindings/js/CachedScriptSourceProviderQt.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,8 @@ static QtBytecodeCacheDelegate* getOrCreateDefaultDelegate()
6262
static QString generateCacheKey(const String& sourceURL)
6363
{
6464
SHA1 sha1;
65-
CString urlUtf8 = sourceURL.utf8();
65+
String strippedURL = URL(sourceURL).strippedForUseAsReport();
66+
CString urlUtf8 = strippedURL.utf8();
6667
sha1.addBytes(std::span<const uint8_t>(reinterpret_cast<const uint8_t*>(urlUtf8.data()), urlUtf8.length()));
6768
SHA1::Digest digest;
6869
sha1.computeHash(digest);

0 commit comments

Comments
 (0)