Open garethsb opened 2 years ago
The different constructors for web::http::experimental::listener::details::http_listener_impl initialize the m_close_task differently.
web::http::experimental::listener::details::http_listener_impl
m_close_task
https://github.com/microsoft/cpprestsdk/blob/07cf589108f50ee40e56c56dc43bfab1022604e0/Release/include/cpprest/http_listener.h#L203-L205
The default constructor that is visible to SDK users since it is inline in the header initializes it like so:
https://github.com/microsoft/cpprestsdk/blob/07cf589108f50ee40e56c56dc43bfab1022604e0/Release/include/cpprest/http_listener.h#L170
However, the other constructors leave the task default initialized:
https://github.com/microsoft/cpprestsdk/blob/07cf589108f50ee40e56c56dc43bfab1022604e0/Release/src/http/listener/http_listener.cpp#L57-L66
A default constructed task behaves quite differently, so this seems like an oversight.
The different constructors for
web::http::experimental::listener::details::http_listener_impl
initialize them_close_task
differently.https://github.com/microsoft/cpprestsdk/blob/07cf589108f50ee40e56c56dc43bfab1022604e0/Release/include/cpprest/http_listener.h#L203-L205
The default constructor that is visible to SDK users since it is inline in the header initializes it like so:
https://github.com/microsoft/cpprestsdk/blob/07cf589108f50ee40e56c56dc43bfab1022604e0/Release/include/cpprest/http_listener.h#L170
However, the other constructors leave the task default initialized:
https://github.com/microsoft/cpprestsdk/blob/07cf589108f50ee40e56c56dc43bfab1022604e0/Release/src/http/listener/http_listener.cpp#L57-L66
A default constructed task behaves quite differently, so this seems like an oversight.