From 2d11841a68953d9c2b41083953c04269e5f769f3 Mon Sep 17 00:00:00 2001 From: Lion Kortlepel Date: Mon, 9 Nov 2020 23:34:06 +0100 Subject: [PATCH] Fix crashing when port checking, remove debug prints --- src/Console.cpp | 2 +- src/logger.cpp | 4 ---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/src/Console.cpp b/src/Console.cpp index 2cddb8e..f434880 100644 --- a/src/Console.cpp +++ b/src/Console.cpp @@ -140,7 +140,7 @@ static void ProcessCompositeInput() { if (CompositeInput.size() == 2 && memcmp(CompositeInput.data(), std::array { 91, 65 }.data(), 2) == 0) { #endif // WIN32 // UP ARROW - info(std::to_string(ConsoleHistoryReadIndex)); + // info(std::to_string(ConsoleHistoryReadIndex)); if (!ConsoleHistory.empty()) { if (ConsoleHistoryReadIndex != 0) { ConsoleHistoryReadIndex -= 1; diff --git a/src/logger.cpp b/src/logger.cpp index 169c49c..2c0de96 100644 --- a/src/logger.cpp +++ b/src/logger.cpp @@ -130,14 +130,10 @@ void warn(const std::string& toPrint) { LogLock.unlock(); } void error(const std::string& toPrint) { - static int ECounter = 0; LogLock.lock(); std::string Print = getDate() + Sec("[ERROR] ") + toPrint + "\n"; ConsoleOut(Print); addToLog(Print); - if (ECounter > 10) - _Exit(7); - ECounter++; LogLock.unlock(); } void except(const std::string& toPrint) {