summaryrefslogtreecommitdiff
path: root/comphelper
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2015-12-15 16:39:14 +0100
committerMichael Stahl <mstahl@redhat.com>2015-12-15 19:55:56 +0100
commitb62394688569421847d79098ac9ac576b62f24f6 (patch)
tree24a9e15e61d941d0b166968ebbea926cf079b32e /comphelper
parent751b6f2ccb4993e1a9007f47bad6b98e53b7ed77 (diff)
sw: set a BaseURL when copying embedded objects
Turns out that SfxObjectShell::CreateShellID() will produce the SfxMedium's base URL if it exists, so EmbeddedObjectContainer::CopyAndGetEmbeddedObject() already has parameters, sw just needs to set them. Change-Id: I36cedfde4e7c2e25c43c66a30d8ca572f099ad69 (cherry picked from commit e4a06fc983fd6a94a6138503c3fc94b567bc3a68)
Diffstat (limited to 'comphelper')
-rw-r--r--comphelper/source/container/embeddedobjectcontainer.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/comphelper/source/container/embeddedobjectcontainer.cxx b/comphelper/source/container/embeddedobjectcontainer.cxx
index 21a2f9dd11c1..b813b96be0dd 100644
--- a/comphelper/source/container/embeddedobjectcontainer.cxx
+++ b/comphelper/source/container/embeddedobjectcontainer.cxx
@@ -696,7 +696,8 @@ uno::Reference < embed::XEmbeddedObject > EmbeddedObjectContainer::CopyAndGetEmb
// objects without persistence are not really stored by the method
if (xObj.is() && StoreEmbeddedObject(xObj, rName, true, rSrcShellID, rDestShellID))
{
- xResult = Get_Impl( rName, xObj);
+ assert(!rDestShellID.isEmpty() && !rDestShellID.startsWith("0x")); // assume that every shell has a base URL
+ xResult = Get_Impl(rName, xObj, &rDestShellID);
if ( !xResult.is() )
{
// this is a case when object has no real persistence