We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0ffa665 commit 8eb113aCopy full SHA for 8eb113a
lib/ocpp/common/websocket/websocket_base.cpp
@@ -74,12 +74,13 @@ void WebsocketBase::disconnect(websocketpp::close::status::value code) {
74
EVLOG_error << "Cannot disconnect a websocket that was not initialized";
75
return;
76
}
77
- if (code == websocketpp::close::status::normal) {
78
- this->shutting_down = true;
79
- }
80
81
{
82
std::lock_guard<std::mutex> lk(this->reconnect_mutex);
+ if (code == websocketpp::close::status::normal) {
+ this->shutting_down = true;
+ }
83
+
84
if (this->reconnect_timer) {
85
this->reconnect_timer.get()->cancel();
86
0 commit comments