summaryrefslogtreecommitdiff
path: root/ucb
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-08-11 11:36:47 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-08-11 13:51:29 +0200
commitdb17a874af37350b3270932175854ee674447bc1 (patch)
treefecc983fb75d3a4072cc7bd344fc824d548deb0d /ucb
parentdd8a400bbbb1b8d5592a870f2036a4df3d005a7d (diff)
convert std::map::insert to std::map::emplace II
Change-Id: Ief8bd59c903625ba65b75114b7b52c3b7ecbd331 Reviewed-on: https://gerrit.libreoffice.org/41019 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'ucb')
-rw-r--r--ucb/source/ucp/file/filtask.cxx4
-rw-r--r--ucb/source/ucp/tdoc/tdoc_storage.cxx5
2 files changed, 4 insertions, 5 deletions
diff --git a/ucb/source/ucp/file/filtask.cxx b/ucb/source/ucp/file/filtask.cxx
index b9bbed77bb7a..23985897f11d 100644
--- a/ucb/source/ucp/file/filtask.cxx
+++ b/ucb/source/ucp/file/filtask.cxx
@@ -2814,8 +2814,8 @@ TaskManager::getContentExchangedEventListeners( const OUString& aOldPrefix,
TaskManager::ContentMap::iterator itold = m_aContent.find( aOldName );
if( itold != m_aContent.end() )
{
- TaskManager::ContentMap::iterator itnew = m_aContent.insert(
- ContentMap::value_type( aNewName,UnqPathData() ) ).first;
+ TaskManager::ContentMap::iterator itnew = m_aContent.emplace(
+ aNewName,UnqPathData() ).first;
// copy Ownership also
delete itnew->second.properties;
diff --git a/ucb/source/ucp/tdoc/tdoc_storage.cxx b/ucb/source/ucp/tdoc/tdoc_storage.cxx
index 2ffe2711e8b3..92db744e22bf 100644
--- a/ucb/source/ucp/tdoc/tdoc_storage.cxx
+++ b/ucb/source/ucp/tdoc/tdoc_storage.cxx
@@ -172,10 +172,9 @@ StorageElementFactory::createStorage( const OUString & rUri,
rtl::Reference< Storage > xElement(
new Storage( m_xContext, this, aUriKey, xParentStorage, xStorage ) );
- aIt = m_aMap.insert(
- StorageMap::value_type(
+ aIt = m_aMap.emplace(
std::pair< OUString, bool >( aUriKey, bWritable ),
- xElement.get() ) ).first;
+ xElement.get() ).first;
aIt->second->m_aContainerIt = aIt;
return aIt->second;