summaryrefslogtreecommitdiff
path: root/http/nghttp2_adapters.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'http/nghttp2_adapters.hpp')
-rw-r--r--http/nghttp2_adapters.hpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/http/nghttp2_adapters.hpp b/http/nghttp2_adapters.hpp
index 9f4dc911d7..05ea68d388 100644
--- a/http/nghttp2_adapters.hpp
+++ b/http/nghttp2_adapters.hpp
@@ -135,9 +135,11 @@ struct nghttp2_session
return nghttp2_session_mem_recv(ptr, buffer.data(), buffer.size());
}
- ssize_t send()
+ std::span<const uint8_t> memSend()
{
- return nghttp2_session_send(ptr);
+ const uint8_t* bytes = nullptr;
+ ssize_t size = nghttp2_session_mem_send(ptr, &bytes);
+ return {bytes, static_cast<size_t>(size)};
}
int submitResponse(int32_t streamId, std::span<const nghttp2_nv> headers,