Skip to content

Commit

Permalink
-fixed unchecked invocation of an error handler in the requester
Browse files Browse the repository at this point in the history
  • Loading branch information
kamchatka-volcano committed May 27, 2023
1 parent 991a455 commit ae56267
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/requesterimpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ std::optional<RequestHandle> RequesterImpl::sendRequest(
initConnection(std::move(params), std::move(data), responseHandler, keepConnection);
connectionOpeningRequestCancelHandler_ = std::make_shared<std::function<void()>>(
[=]{
errorInfoHandler_("Connection initialization cancelled");
notifyAboutError("Connection initialization cancelled");
connectionState_ = ConnectionState::NotConnected;
responseHandler(std::nullopt);
});
Expand Down Expand Up @@ -109,7 +109,7 @@ std::optional<RequestHandle> RequesterImpl::doSendRequest(
bool keepConnection)
{
if (requestIdPool_.empty()){
errorInfoHandler_("Maximum requests number reached");
notifyAboutError("Maximum requests number reached");
responseHandler(std::nullopt);
return std::nullopt;
}
Expand Down

0 comments on commit ae56267

Please sign in to comment.