mirror of
https://github.com/boostorg/beast.git
synced 2025-08-01 22:04:34 +02:00
Don't use-after-free in test:
fix #1327 Move construction of a queued completion handler was accessing destroyed data. Signed-off-by: Damian Jarek <damian.jarek93@gmail.com>
This commit is contained in:
committed by
Vinnie Falco
parent
49cdabca19
commit
69f3e4d8fb
@@ -427,6 +427,7 @@ public:
|
||||
testIssue954()
|
||||
{
|
||||
echo_server es{log};
|
||||
multi_buffer b;
|
||||
boost::asio::io_context ioc;
|
||||
stream<test::stream> ws{ioc};
|
||||
ws.next_layer().connect(es.stream());
|
||||
@@ -443,7 +444,6 @@ public:
|
||||
{
|
||||
called_cb = true;
|
||||
});
|
||||
multi_buffer b;
|
||||
ws.async_read(b,
|
||||
[&](error_code, std::size_t)
|
||||
{
|
||||
|
Reference in New Issue
Block a user