CMakeLists.txt: requires C++23 standard
CMakeLists.txt: add compiler version checks adc_netserver.h: add AdcTrivialLogger class (use of 'deduced this' feature of C++23 standard); AdcGenericNetServer class now has basic based on std::basic_ostream logging capability
This commit is contained in:
@@ -246,9 +246,11 @@ public:
|
||||
_netService.asyncReceive(
|
||||
[self, this](netservice_t::async_callback_err_t ec, message_t msg) {
|
||||
if (ec) {
|
||||
std::string str("asyncReceive operation completed with error: ");
|
||||
netservice_t::formatError(ec, str);
|
||||
_serverPtr->errorMessage(str);
|
||||
// std::string str("asyncReceive operation completed with error: ");
|
||||
// netservice_t::formatError(ec, str);
|
||||
// _serverPtr->errorMessage(str);
|
||||
_serverPtr->logError("asyncReceive operation completed with error: {}",
|
||||
netservice_t::formattableError(ec));
|
||||
stop();
|
||||
} else {
|
||||
auto msg_sptr = std::make_shared<message_t>(std::move(msg));
|
||||
@@ -261,9 +263,11 @@ public:
|
||||
*msg_sptr,
|
||||
[self, msg_sptr, this](netservice_t::async_callback_err_t ec) {
|
||||
if (ec) {
|
||||
std::string str("asyncSend operation completed with error: ");
|
||||
netservice_t::formatError(ec, str);
|
||||
_serverPtr->errorMessage(str);
|
||||
// std::string str("asyncSend operation completed with error: ");
|
||||
// netservice_t::formatError(ec, str);
|
||||
// _serverPtr->errorMessage(str);
|
||||
_serverPtr->logError("asyncSend operation completed with error: {}",
|
||||
netservice_t::formattableError(ec));
|
||||
stop();
|
||||
} else {
|
||||
start();
|
||||
|
||||
Reference in New Issue
Block a user