summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/util/corestr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/util/corestr.cpp')
-rw-r--r--src/lib/util/corestr.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/lib/util/corestr.cpp b/src/lib/util/corestr.cpp
index 336d788cabb..ce5976869d4 100644
--- a/src/lib/util/corestr.cpp
+++ b/src/lib/util/corestr.cpp
@@ -217,14 +217,13 @@ int strprintf(std::string &str, const char *format, ...)
return retVal;
}
-std::string strformat(std::string &str, const char *format, ...)
+std::string strformat(const char *format, ...)
{
std::string retVal;
va_list ap;
va_start(ap, format);
- strvprintf(str, format, ap);
+ strvprintf(retVal, format, ap);
va_end(ap);
- retVal.assign(str);
return retVal;
}