Skip to content

Commit 98c5306

Browse files
committed
Fixing compiler error on VS2012.
1 parent 2f61433 commit 98c5306

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

Release/libs/websocketpp/websocketpp/transport/asio/connection.hpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -442,8 +442,8 @@ class connection : public config::socket_type::socket_con_type {
442442
if (ec) {
443443
// reset the handlers to break the circular reference:
444444
// this->handler->this
445-
m_async_read_handler = async_read_handler{};
446-
m_async_write_handler = async_write_handler{};
445+
m_async_read_handler = async_read_handler();
446+
m_async_write_handler = async_write_handler();
447447
}
448448

449449
return ec;
@@ -969,12 +969,12 @@ class connection : public config::socket_type::socket_con_type {
969969
// Reset cached handlers now that we won't be reading or writing anymore
970970
// These cached handlers store shared pointers to this connection and
971971
// will leak the connection if not destroyed.
972-
m_async_read_handler = async_read_handler{};
973-
m_async_write_handler = async_write_handler{};
974-
m_init_handler = init_handler{};
972+
m_async_read_handler = async_read_handler();
973+
m_async_write_handler = async_write_handler();
974+
m_init_handler = init_handler();
975975

976-
m_read_handler = read_handler{};
977-
m_write_handler = write_handler{};
976+
m_read_handler = read_handler();
977+
m_write_handler = write_handler();
978978

979979
timer_ptr shutdown_timer;
980980
shutdown_timer = set_timer(

0 commit comments

Comments
 (0)