summaryrefslogtreecommitdiff
path: root/lib/common/DebugMemLeakFinder.cpp
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2014-12-22 23:05:12 +0000
committerChris Wilson <chris+github@qwirx.com>2014-12-22 23:05:12 +0000
commite88418c0145ddeba97116e49074dd8e2e9edea7a (patch)
tree889048dff35024f2403e9360d7e7884cf79d696f /lib/common/DebugMemLeakFinder.cpp
parenta6f52d5d593a0ebe16326b04df367ede82c9511e (diff)
Make memleakfinder_setup_exit_report() take a std::string, for C++ style.
Diffstat (limited to 'lib/common/DebugMemLeakFinder.cpp')
-rw-r--r--lib/common/DebugMemLeakFinder.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/common/DebugMemLeakFinder.cpp b/lib/common/DebugMemLeakFinder.cpp
index a7d87528..d2109d7b 100644
--- a/lib/common/DebugMemLeakFinder.cpp
+++ b/lib/common/DebugMemLeakFinder.cpp
@@ -586,9 +586,10 @@ extern "C" void memleakfinder_atexit()
memleakfinder_reportleaks_appendfile(atexit_filename, atexit_markertext);
}
-void memleakfinder_setup_exit_report(const char *filename, const char *markertext)
+void memleakfinder_setup_exit_report(const std::string& filename,
+ const char *markertext)
{
- ::strncpy(atexit_filename, filename, sizeof(atexit_filename)-1);
+ ::strncpy(atexit_filename, filename.c_str(), sizeof(atexit_filename)-1);
::strncpy(atexit_markertext, markertext, sizeof(atexit_markertext)-1);
atexit_filename[sizeof(atexit_filename)-1] = 0;
atexit_markertext[sizeof(atexit_markertext)-1] = 0;