diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-09-11 11:29:40 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2019-05-30 16:13:03 +0200 |
commit | e19635027d39cda6b7ee4da5d6c7e974be17968a (patch) | |
tree | 96fc72a870202d156bcca93098e91809537065fb | |
parent | 729f64daed2fd7dfaca48e338e2e57ddfebd5400 (diff) |
clang-tidy modernize-use-emplace in hwpfilter..lotuswordpro
(cherry picked from commit 7ca4ea54b4d610104df1b88ae5b04c2081a4a429)
Change-Id: Ic11634ca28396fd156390c511087bae03bd5fb70
Reviewed-on: https://gerrit.libreoffice.org/42156
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r-- | jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx | 9 | ||||
-rw-r--r-- | jvmfwk/plugins/sunmajor/pluginlib/util.cxx | 2 | ||||
-rw-r--r-- | jvmfwk/source/framework.cxx | 3 |
3 files changed, 6 insertions, 8 deletions
diff --git a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx index 65c5c9d8d748..1f4dac0e9e25 100644 --- a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx +++ b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx @@ -722,7 +722,7 @@ javaPluginError jfw_plugin_startJavaVirtualMachine( // JNI_CreateJavaVM. This happens when the LD_LIBRARY_PATH does not contain // all some directories of the Java installation. This is necessary for // all versions below 1.5.1 - options.push_back(Option("abort", reinterpret_cast<void*>(abort_handler))); + options.emplace_back("abort", reinterpret_cast<void*>(abort_handler)); bool hasStackSize = false; for (int i = 0; i < cOptions; i++) { @@ -743,10 +743,10 @@ javaPluginError jfw_plugin_startJavaVirtualMachine( if (opt.startsWith("-Xss")) { hasStackSize = true; } - options.push_back(Option(opt, arOptions[i].extraInfo)); + options.emplace_back(opt, arOptions[i].extraInfo); } if (addForceInterpreted) { - options.push_back(Option("-Xint", nullptr)); + options.emplace_back("-Xint", nullptr); } if (!hasStackSize) { #if defined LINUX && (defined X86 || defined X86_64) @@ -772,8 +772,7 @@ javaPluginError jfw_plugin_startJavaVirtualMachine( "jfw", "huge RLIMIT_STACK " << l.rlim_cur << " -> 8192K"); l.rlim_cur = 8192 * 1024; } - options.push_back( - Option("-Xss" + OString::number(l.rlim_cur), nullptr)); + options.emplace_back("-Xss" + OString::number(l.rlim_cur), nullptr); } else { int e = errno; SAL_WARN("jfw", "getrlimit(RLIMIT_STACK) failed with errno " << e); diff --git a/jvmfwk/plugins/sunmajor/pluginlib/util.cxx b/jvmfwk/plugins/sunmajor/pluginlib/util.cxx index 8a0138eee239..3bd50ffe04d4 100644 --- a/jvmfwk/plugins/sunmajor/pluginlib/util.cxx +++ b/jvmfwk/plugins/sunmajor/pluginlib/util.cxx @@ -528,7 +528,7 @@ bool getJavaProps(const OUString & exePath, } #endif - props.push_back(std::make_pair(sKey, sVal)); + props.emplace_back(sKey, sVal); } if (rs != FileHandleReader::RESULT_ERROR && !props.empty()) diff --git a/jvmfwk/source/framework.cxx b/jvmfwk/source/framework.cxx index ddc5e6c19747..5d401a0486ca 100644 --- a/jvmfwk/source/framework.cxx +++ b/jvmfwk/source/framework.cxx @@ -351,8 +351,7 @@ javaFrameworkError jfw_findAndSelectJRE(std::unique_ptr<JavaInfo> *pInfo) jfw::VersionInfo versionInfo = aVendorSettings.getVersionInformation(vendor); - versionInfos.push_back( - std::pair<OUString, jfw::VersionInfo>(vendor, versionInfo)); + versionInfos.emplace_back(vendor, versionInfo); } std::vector<rtl::Reference<jfw_plugin::VendorBase>> infos; |