From 9bace227c51e214c109e19072ad495ef16618f43 Mon Sep 17 00:00:00 2001 From: staviq Date: Fri, 25 Aug 2023 18:24:55 +0200 Subject: [PATCH] stub LOG_DUMP_CMDLINE for WIN32 for now --- common/log.h | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/common/log.h b/common/log.h index 926a25e35..e3e45a5fc 100644 --- a/common/log.h +++ b/common/log.h @@ -491,14 +491,16 @@ inline void log_print_usage() fprintf(stdout, " Log file will be tagged with unique ID and written as \"..log\"\n"); /* */ } +#ifndef _WIN32 +// TODO: +// Windows doesn't seem to like this somehow + #define LOG_DUMP_CMDLINE( argc, argv ) _log_dump_cmdline(argc,argv) // INTERNAL, DO NOT USE inline void _log_dump_cmdline(int argc, char **argv) { - // TODO: - // Windows doesn't seem to like this somehow - std::string buf{""}; + std::string buf; for (int i = 0; i < argc; ++i) { if (std::string(argv[i]).find(' ') != std::string::npos) @@ -513,6 +515,10 @@ inline void _log_dump_cmdline(int argc, char **argv) LOGLN("Cmd:%s", buf.c_str()) } +#else +#define LOG_DUMP_CMDLINE(...) // dummy stub +#endif + #define LOG_TOSTR(var) _log_var_to_string(var).c_str() inline std::string _log_var_to_string(bool var)