Skip to content

Commit

Permalink
fix compiler errors with boost asio
Browse files Browse the repository at this point in the history
  • Loading branch information
yourWaifu committed Feb 6, 2025
1 parent 6f1ab9f commit d51a23a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions include/sleepy_discord/asio_websocketconnection.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@
#include <asio/read.hpp>
#include <asio/streambuf.hpp>
#endif
extern "C" {
#include <openssl/x509.h>
#include <openssl/evp.h>
#include <openssl/rand.h>
#include <openssl/sha.h>
}
#include "endian.h"
#include "version_helper.h"

Expand Down Expand Up @@ -117,11 +119,11 @@ namespace SleepyDiscord {

cancelSignal->emit(asio::cancellation_type::all);
self->logError("connect took too long, canceling", err);
self->socketPtr->async_shutdown();
self->socketPtr->async_shutdown([](const asio::error_code& _) {});
});

auto cleanUp = [self, connectDeadline]() {
self->socketPtr->async_shutdown();
self->socketPtr->async_shutdown([](const asio::error_code& _) {});
connectDeadline->cancel();
};

Expand Down

0 comments on commit d51a23a

Please sign in to comment.