From cda8168c58fa33d048581196e25e3c8ae7c68766 Mon Sep 17 00:00:00 2001 From: Lion Kortlepel Date: Tue, 30 Mar 2021 16:15:44 +0200 Subject: [PATCH] fix boost crash --- src/Http.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/Http.cpp b/src/Http.cpp index 47bcbb2..886e103 100644 --- a/src/Http.cpp +++ b/src/Http.cpp @@ -1,11 +1,10 @@ #include "Http.h" - +#include "Common.h" #include #include #include #include -#include "Common.h" namespace beast = boost::beast; // from namespace http = beast::http; // from @@ -140,5 +139,8 @@ std::string Http::POST(const std::string& host, const std::string& target, const } catch (const std::exception& e) { error(e.what()); return "-1"; + } catch (const boost::system::system_error& e) { + error(e.what()); + return "-1"; } -} \ No newline at end of file +}