Kaydet (Commit) 86218bda authored tarafından Cao Cuong Ngo's avatar Cao Cuong Ngo

Fix fdo#68894 Cmis crashes on start up.

The reason of the crash is that the recent file opening
feature can't get the session automatically.

Change-Id: I6890c04cfdafc81d19c6b2b2024896df040fe091
üst 34f4d257
...@@ -364,6 +364,17 @@ namespace cmis ...@@ -364,6 +364,17 @@ namespace cmis
libcmis::ObjectPtr Content::getObject( const uno::Reference< ucb::XCommandEnvironment >& xEnv ) throw ( libcmis::Exception ) libcmis::ObjectPtr Content::getObject( const uno::Reference< ucb::XCommandEnvironment >& xEnv ) throw ( libcmis::Exception )
{ {
// can't get the session for some reason
// the recent file openning at start up is an example.
try
{
if ( !getSession( xEnv ) )
return m_pObject;
}
catch ( uno::RuntimeException& )
{
return m_pObject;
}
if ( !m_pObject.get() ) if ( !m_pObject.get() )
{ {
if ( !m_sObjectId.isEmpty( ) ) if ( !m_sObjectId.isEmpty( ) )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment