mutable buffer
This commit is contained in:
parent
b2706e48a8
commit
d075015359
|
@ -0,0 +1,17 @@
|
|||
#include <boost/asio.hpp>
|
||||
#include <iostream>
|
||||
#include <memory>
|
||||
|
||||
using namespace boost;
|
||||
using namespace std;
|
||||
|
||||
int main()
|
||||
{
|
||||
constexpr size_t k_BufSizeBytes = 20;
|
||||
|
||||
auto buf = make_unique<char[]>(k_BufSizeBytes);
|
||||
|
||||
asio::mutable_buffers_1 input_buf = asio::buffer(static_cast<void*>(buf.get()), k_BufSizeBytes);
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
}
|
Loading…
Reference in New Issue