aboutsummaryrefslogtreecommitdiff
path: root/zenserver/zenserver.cpp
diff options
context:
space:
mode:
authorMatt Peters <[email protected]>2022-01-10 10:57:59 -0700
committerMatt Peters <[email protected]>2022-01-10 10:57:59 -0700
commit4a12683b27adb31bde9eb8f7df3b9e9cc8ec680a (patch)
treec8b2939d400dd4bccae73d2782b15c65d30db19d /zenserver/zenserver.cpp
parentAdd WaitForQuiescence RPC (diff)
parentTwo missing override keywords (diff)
downloadzen-wait_for_quiescence.tar.xz
zen-wait_for_quiescence.zip
Merge branch 'main' into wait_for_quiescencewait_for_quiescence
Diffstat (limited to 'zenserver/zenserver.cpp')
-rw-r--r--zenserver/zenserver.cpp15
1 files changed, 6 insertions, 9 deletions
diff --git a/zenserver/zenserver.cpp b/zenserver/zenserver.cpp
index 6e5d2fe93..40d40e908 100644
--- a/zenserver/zenserver.cpp
+++ b/zenserver/zenserver.cpp
@@ -114,7 +114,6 @@ ZEN_THIRD_PARTY_INCLUDES_END
namespace zen {
using namespace std::literals;
-using namespace fmt::literals;
namespace utils {
asio::error_code ResolveHostname(asio::io_context& Ctx,
@@ -139,7 +138,7 @@ namespace utils {
{
for (const asio::ip::tcp::endpoint Ep : Endpoints)
{
- OutEndpoints.push_back("http://{}:{}"_format(Ep.address().to_string(), Ep.port()));
+ OutEndpoints.push_back(fmt::format("http://{}:{}", Ep.address().to_string(), Ep.port()));
}
}
@@ -152,8 +151,6 @@ class ZenServer : public IHttpStatusProvider
public:
void Initialize(const ZenServerOptions& ServerOptions, ZenServerState::ZenServerEntry* ServerEntry)
{
- using namespace fmt::literals;
-
m_ServerEntry = ServerEntry;
m_DebugOptionForcedCrash = ServerOptions.ShouldCrash;
const int ParentPid = ServerOptions.OwnerPid;
@@ -180,11 +177,11 @@ public:
// Initialize/check mutex based on base port
- std::string MutexName = "zen_{}"_format(ServerOptions.BasePort);
+ std::string MutexName = fmt::format("zen_{}", ServerOptions.BasePort);
if (zen::NamedMutex::Exists(MutexName) || ((m_ServerMutex.Create(MutexName) == false)))
{
- throw std::runtime_error("Failed to create mutex '{}' - is another instance already running?"_format(MutexName).c_str());
+ throw std::runtime_error(fmt::format("Failed to create mutex '{}' - is another instance already running?", MutexName).c_str());
}
InitializeState(ServerOptions);
@@ -585,7 +582,7 @@ ZenServer::InitializeState(const ZenServerOptions& ServerOptions)
else
{
WipeState = true;
- WipeReason = "No manifest present at '{}'"_format(ManifestPath);
+ WipeReason = fmt::format("No manifest present at '{}'", ManifestPath);
}
}
else
@@ -598,7 +595,7 @@ ZenServer::InitializeState(const ZenServerOptions& ServerOptions)
ZEN_ERROR("Manifest validation failed: {}, state will be wiped", ValidationResult);
WipeState = true;
- WipeReason = "Validation of manifest at '{}' failed: {}"_format(ManifestPath, ValidationResult);
+ WipeReason = fmt::format("Validation of manifest at '{}' failed: {}", ManifestPath, ValidationResult);
}
else
{
@@ -609,7 +606,7 @@ ZenServer::InitializeState(const ZenServerOptions& ServerOptions)
if (ManifestVersion != ZEN_CFG_SCHEMA_VERSION)
{
WipeState = true;
- WipeReason = "Manifest schema version: {}, differs from required: {}"_format(ManifestVersion, ZEN_CFG_SCHEMA_VERSION);
+ WipeReason = fmt::format("Manifest schema version: {}, differs from required: {}", ManifestVersion, ZEN_CFG_SCHEMA_VERSION);
}
}
}