mirror of
https://gitee.com/openharmony/third_party_nghttp2
synced 2024-11-27 18:10:47 +00:00
nghttpx: Use SHRPX_MAX_UDP_PAYLOAD_SIZE
This commit is contained in:
parent
d2729193c7
commit
82cd110dbe
@ -295,7 +295,7 @@ int QUICConnectionHandler::send_retry(
|
||||
return -1;
|
||||
}
|
||||
|
||||
std::array<uint8_t, 1280> buf;
|
||||
std::array<uint8_t, SHRPX_MAX_UDP_PAYLOAD_SIZE> buf;
|
||||
|
||||
auto nwrite =
|
||||
ngtcp2_crypto_write_retry(buf.data(), buf.size(), version, &iscid,
|
||||
@ -319,7 +319,7 @@ int QUICConnectionHandler::send_version_negotiation(
|
||||
sv[0] = generate_reserved_version(remote_addr, version);
|
||||
sv[1] = NGTCP2_PROTO_VER_V1;
|
||||
|
||||
std::array<uint8_t, 1280> buf;
|
||||
std::array<uint8_t, SHRPX_MAX_UDP_PAYLOAD_SIZE> buf;
|
||||
|
||||
uint8_t rand_byte;
|
||||
util::random_bytes(&rand_byte, &rand_byte + 1, worker_->get_randgen());
|
||||
@ -364,7 +364,7 @@ int QUICConnectionHandler::send_stateless_reset(const UpstreamAddr *faddr,
|
||||
return -1;
|
||||
}
|
||||
|
||||
std::array<uint8_t, 1280> buf;
|
||||
std::array<uint8_t, SHRPX_MAX_UDP_PAYLOAD_SIZE> buf;
|
||||
|
||||
auto nwrite =
|
||||
ngtcp2_pkt_write_stateless_reset(buf.data(), buf.size(), token.data(),
|
||||
|
Loading…
Reference in New Issue
Block a user