From 0fecc2ebf0f52bd3694110dd455498642d733286 Mon Sep 17 00:00:00 2001 From: Stefan Boberg Date: Fri, 27 Sep 2024 16:57:17 +0200 Subject: work around issues compiling fmt::join call on mac (#170) --- src/zenserver/config.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/zenserver/config.cpp') diff --git a/src/zenserver/config.cpp b/src/zenserver/config.cpp index 2023a9d51..4fc928d2c 100644 --- a/src/zenserver/config.cpp +++ b/src/zenserver/config.cpp @@ -577,7 +577,15 @@ ParseCliOptions(int argc, char* argv[], ZenServerOptions& ServerOptions) } #endif - ServerOptions.CommandLine = fmt::format("{}", fmt::join(std::span((const char**)argv, size_t(argc)), " ")); + for (int i = 0; i < argc; ++i) + { + if (i) + { + ServerOptions.CommandLine.push_back(' '); + } + + ServerOptions.CommandLine += argv[i]; + } // Note to those adding future options; std::filesystem::path-type options // must be read into a std::string first. As of cxxopts-3.0.0 it uses a >> -- cgit v1.2.3