--- a/mtpfws/mtpfw/daemon/server/src/cmtpserver.cpp Wed Jun 09 10:36:33 2010 +0300
+++ b/mtpfws/mtpfw/daemon/server/src/cmtpserver.cpp Mon Jun 21 16:36:59 2010 +0300
@@ -73,6 +73,7 @@
{
__FLOG(_L8("~CMTPServer - Entry"));
delete iShutdown;
+ iShutdown = NULL;
iFrameworkSingletons.ConnectionMgr().StopTransports();
iFrameworkSingletons.DpController().UnloadDataProviders();
iFrameworkSingletons.Close();
@@ -139,12 +140,6 @@
if (--iSessionCount==0 && iFrameworkSingletons.ConnectionMgr().TransportCount() == 0)
{
// No active MTP client API sessions remain, start the shutdown timer.
- if (!iShutdown)
- {
- TRAPD(error, iShutdown = CMTPShutdown::NewL());
- __FLOG(_L8("CMTPShutdown Loaded- Entry"));
- UNUSED_VAR(error);
- }
if (iShutdown)
{
__FLOG(_L8("Shutdown Started - Entry"));
@@ -193,6 +188,12 @@
__FLOG(_L8("ConstructL - Entry"));
StartL(KMTPServerName);
iFrameworkSingletons.OpenL();
+ if (!iShutdown)
+ {
+ TRAPD(error, iShutdown = CMTPShutdown::NewL());
+ __FLOG(_L8("CMTPShutdown Loaded- Entry"));
+ UNUSED_VAR(error);
+ }
__FLOG(_L8("ConstructL - Exit"));
}