From 8b0c2c31b64d05c09943a5fd112c81cd4b72cc8e Mon Sep 17 00:00:00 2001 From: Vladislav Kalugin Date: Fri, 10 Feb 2023 18:43:13 +0300 Subject: [PATCH] Fix --- server/src/Synchronizer.cpp | 10 ++++------ server/test/framework/BaseTest.h | 2 +- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/server/src/Synchronizer.cpp b/server/src/Synchronizer.cpp index 8fdc5d346..16d3702bb 100644 --- a/server/src/Synchronizer.cpp +++ b/server/src/Synchronizer.cpp @@ -64,10 +64,9 @@ bool Synchronizer::isProbablyOutdatedStubs(const fs::path &srcFilePath) const { } catch (...) { return true; } - if (!fs::exists(srcFilePath)){ + if (!fs::exists(srcFilePath)) { srcTimestamp = time(NULL); - } - else { + } else { srcTimestamp = Synchronizer::getFileOutdatedTime(srcFilePath); } return stubTimestamp <= srcTimestamp; @@ -80,10 +79,9 @@ bool Synchronizer::isProbablyOutdatedWrappers(const fs::path &srcFilePath) const } long long wrapperTimestamp, srcTimestamp; wrapperTimestamp = Synchronizer::getFileOutdatedTime(wrapperFilePath); - if (!fs::exists(srcFilePath)){ + if (!fs::exists(srcFilePath)) { srcTimestamp = time(NULL); - } - else { + } else { srcTimestamp = Synchronizer::getFileOutdatedTime(srcFilePath); } return wrapperTimestamp <= srcTimestamp; diff --git a/server/test/framework/BaseTest.h b/server/test/framework/BaseTest.h index 33c888b1f..5da9aa570 100644 --- a/server/test/framework/BaseTest.h +++ b/server/test/framework/BaseTest.h @@ -23,7 +23,7 @@ class BaseTest : public testing::Test { CompilerName compilerName = CompilerName::CLANG; std::string buildDirRelativePath; - std::string clientProjectPath; + std::string clientProjectPath = ""; fs::path buildPath; std::vector srcPaths;