sc/source/ui/collab/contacts.cxx | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-)
New commits: commit e708ec7aa52567fcd0bc658e4755b3e5168445d7 Author: Eike Rathke <er...@redhat.com> Date: Mon Jul 16 17:40:52 2012 +0200 tubes: do not use mpManager after unref Change-Id: If8bb6da915d6470b9796e26c46f3e8f2000879fd diff --git a/sc/source/ui/collab/contacts.cxx b/sc/source/ui/collab/contacts.cxx index 725b1f5..51bd1e4 100644 --- a/sc/source/ui/collab/contacts.cxx +++ b/sc/source/ui/collab/contacts.cxx @@ -82,6 +82,9 @@ class TubeContacts : public ModelessDialog void Listen() { + if (!mpManager) + return ; + if (!mpManager->registerClients()) { fprintf( stderr, "Could not register client handlers.\n" ); @@ -103,6 +106,9 @@ class TubeContacts : public ModelessDialog void StartBuddySession() { + if (!mpManager) + return ; + AccountContact *pAC = NULL; if (maList.FirstSelected()) pAC = static_cast<AccountContact*> (maList.FirstSelected()->GetUserData()); @@ -122,6 +128,9 @@ class TubeContacts : public ModelessDialog void StartGroupSession() { + if (!mpManager) + return ; + AccountContact *pAC = NULL; if (maList.FirstSelected()) pAC = static_cast<AccountContact*> (maList.FirstSelected()->GetUserData()); @@ -172,6 +181,7 @@ public: { fprintf( stderr, "Could not create AccountManager.\n" ); mpManager->unref(); + mpManager = NULL; } } maBtnConnect.SetClickHdl( LINK( this, TubeContacts, BtnConnectHdl ) ); @@ -194,7 +204,8 @@ public: } virtual ~TubeContacts() { - mpManager->unref(); + if (mpManager) + mpManager->unref(); } static rtl::OUString fromUTF8( const char *pStr ) _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits