mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 05:41:12 +00:00
Bug 1734132 - Add neqo glue code to send priority updates r=necko-reviewers,dragana
Differential Revision: https://phabricator.services.mozilla.com/D129003
This commit is contained in:
parent
6edbd3270e
commit
52ae51abfa
@ -62,6 +62,12 @@ class NeqoHttp3Conn final {
|
||||
&aHeaders, aStreamId, aUrgency, aIncremental);
|
||||
}
|
||||
|
||||
nsresult PriorityUpdate(uint64_t aStreamId, uint8_t aUrgency,
|
||||
bool aIncremental) {
|
||||
return neqo_http3conn_priority_update(this, aStreamId, aUrgency,
|
||||
aIncremental);
|
||||
}
|
||||
|
||||
nsresult SendRequestBody(uint64_t aStreamId, const uint8_t* aBuf,
|
||||
uint32_t aCount, uint32_t* aCountRead) {
|
||||
return neqo_htttp3conn_send_request_body(this, aStreamId, aBuf, aCount,
|
||||
|
@ -410,6 +410,23 @@ pub extern "C" fn neqo_http3conn_fetch(
|
||||
}
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn neqo_http3conn_priority_update(
|
||||
conn: &mut NeqoHttp3Conn,
|
||||
stream_id: u64,
|
||||
urgency: u8,
|
||||
incremental: bool,
|
||||
) -> nsresult {
|
||||
if urgency >= 8 {
|
||||
return NS_ERROR_INVALID_ARG;
|
||||
}
|
||||
let priority = Priority::new(urgency, incremental);
|
||||
match conn.conn.priority_update(stream_id, priority) {
|
||||
Ok(_) => NS_OK,
|
||||
Err(_) => NS_ERROR_UNEXPECTED,
|
||||
}
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn neqo_htttp3conn_send_request_body(
|
||||
conn: &mut NeqoHttp3Conn,
|
||||
|
Loading…
Reference in New Issue
Block a user