From cc2dc2396387aae412100e70c3841eba9c08a31d Mon Sep 17 00:00:00 2001 From: adjoly Date: Tue, 22 Apr 2025 16:41:28 +0200 Subject: [PATCH] =?UTF-8?q?=E3=80=8C=F0=9F=94=A8=E3=80=8D=20fix:=20fixed?= =?UTF-8?q?=20some=20exception=20handling=20that=20were=20a=20little=20SUS?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- exemples/test.toml | 2 +- src/server/Server.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/exemples/test.toml b/exemples/test.toml index 8c0d802..a513196 100644 --- a/exemples/test.toml +++ b/exemples/test.toml @@ -2,7 +2,7 @@ log_file = "test.log" [server] server_names = { "localhost", "2B5.local" } -host = "0.0.0.0" +host = "localhost" port = 8080 [server.error_pages] diff --git a/src/server/Server.cpp b/src/server/Server.cpp index 976b9b6..0dd8220 100644 --- a/src/server/Server.cpp +++ b/src/server/Server.cpp @@ -6,7 +6,7 @@ /* By: adjoly +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2025/04/11 16:11:40 by adjoly #+# #+# */ -/* Updated: 2025/04/22 16:34:40 by adjoly ### ########.fr */ +/* Updated: 2025/04/22 16:37:31 by adjoly ### ########.fr */ /* */ /* ************************************************************************** */ @@ -149,7 +149,7 @@ Server::Server(config::Config *conf) : _conf(conf) { try { _setup(); _run(); - } catch (std::exception &e) { + } catch (std::runtime_error &e) { _log->error(e.what()); } }