Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
http2: remove duplicate codeblock
  • Loading branch information
AVVS committed Nov 19, 2024
commit 6cefd813ff32b09c4d9b61f36b529acaac3b2f7f
6 changes: 1 addition & 5 deletions src/node_http2.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1314,11 +1314,7 @@ int Http2Session::OnDataChunkReceived(nghttp2_session* handle,
} else {
memcpy(buf.base, data, avail);
}
if (buf.base == nullptr) [[likely]] {
buf.base = reinterpret_cast<char*>(const_cast<uint8_t*>(data));
} else {
memcpy(buf.base, data, avail);
}

data += avail;
len -= avail;
stream->EmitRead(avail, buf);
Expand Down