diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:34:50 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:34:50 +0000 |
commit | def92d1b8e9d373e2f6f27c366d578d97d8960c6 (patch) | |
tree | 2ef34b9ad8bb9a9220e05d60352558b15f513894 /netwerk/protocol/http/Http3Stream.cpp | |
parent | Adding debian version 125.0.3-1. (diff) | |
download | firefox-def92d1b8e9d373e2f6f27c366d578d97d8960c6.tar.xz firefox-def92d1b8e9d373e2f6f27c366d578d97d8960c6.zip |
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'netwerk/protocol/http/Http3Stream.cpp')
-rw-r--r-- | netwerk/protocol/http/Http3Stream.cpp | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/netwerk/protocol/http/Http3Stream.cpp b/netwerk/protocol/http/Http3Stream.cpp index 4f33ca07e2..4bb6b30925 100644 --- a/netwerk/protocol/http/Http3Stream.cpp +++ b/netwerk/protocol/http/Http3Stream.cpp @@ -42,7 +42,7 @@ Http3Stream::Http3Stream(nsAHttpTransaction* httpTransaction, mTransactionBrowserId = trans->BrowserId(); } - SetPriority(cos.Flags()); + mPriorityUrgency = nsHttpHandler::UrgencyFromCoSFlags(cos.Flags()); SetIncremental(cos.Incremental()); } @@ -80,31 +80,6 @@ bool Http3Stream::GetHeadersString(const char* buf, uint32_t avail, return true; } -void Http3Stream::SetPriority(uint32_t aCos) { - if (aCos & nsIClassOfService::UrgentStart) { - // coming from an user interaction => response should be the highest - // priority - mPriorityUrgency = 1; - } else if (aCos & nsIClassOfService::Leader) { - // main html document normal priority - mPriorityUrgency = 2; - } else if (aCos & nsIClassOfService::Unblocked) { - mPriorityUrgency = 3; - } else if (aCos & nsIClassOfService::Follower) { - mPriorityUrgency = 4; - } else if (aCos & nsIClassOfService::Speculative) { - mPriorityUrgency = 6; - } else if (aCos & nsIClassOfService::Background) { - // background tasks can be deprioritzed to the lowest priority - mPriorityUrgency = 6; - } else if (aCos & nsIClassOfService::Tail) { - mPriorityUrgency = 6; - } else { - // all others get a lower priority than the main html document - mPriorityUrgency = 4; - } -} - void Http3Stream::SetIncremental(bool incremental) { mPriorityIncremental = incremental; } |