fwk162: #i115902# review usage of SfxObjectShellRef, SfxObjecShellLock
This commit is contained in:
parent
e260bc4391
commit
02e1029d8c
1 changed files with 3 additions and 2 deletions
|
@ -1508,7 +1508,8 @@ ULONG SwNewDBMgr::GetColumnFmt( uno::Reference< XDataSource> xSource,
|
|||
if(!xSource.is())
|
||||
{
|
||||
uno::Reference<XChild> xChild(xConnection, UNO_QUERY);
|
||||
xSource = uno::Reference<XDataSource>(xChild->getParent(), UNO_QUERY);
|
||||
if ( xChild.is() )
|
||||
xSource = uno::Reference<XDataSource>(xChild->getParent(), UNO_QUERY);
|
||||
}
|
||||
if(xSource.is() && xConnection.is() && xColumn.is() && pNFmtr)
|
||||
{
|
||||
|
@ -2876,7 +2877,7 @@ sal_Int32 SwNewDBMgr::MergeDocuments( SwMailMergeConfigItem& rMMConfig,
|
|||
try
|
||||
{
|
||||
// create a target docshell to put the merged document into
|
||||
SfxObjectShellLock xTargetDocShell( new SwDocShell( SFX_CREATE_MODE_STANDARD ) );
|
||||
SfxObjectShellRef xTargetDocShell( new SwDocShell( SFX_CREATE_MODE_STANDARD ) );
|
||||
xTargetDocShell->DoInitNew( 0 );
|
||||
SfxViewFrame* pTargetFrame = SfxViewFrame::LoadHiddenDocument( *xTargetDocShell, 0 );
|
||||
|
||||
|
|
Loading…
Reference in a new issue