Browse Source

Explicitly instantiate string with source filename

Christoph Stelz 3 months ago
parent
commit
a5e3bd9562
1 changed files with 3 additions and 1 deletions
  1. 3 1
      src/ipc_debug.cpp

+ 3 - 1
src/ipc_debug.cpp

@@ -215,7 +215,9 @@ void debug_ipc_assert_equal_array(void *value, size_t size) {
 }
 
 void debug_ipc_assert_source_location(const char *source_file, const long int line_number) {
-    debug_ipc_assert_equal(std::string(source_file));
+    std::string fname(source_file);
+
+    debug_ipc_assert_equal(fname);
     debug_ipc_assert_equal(line_number);
 }