mtpfws/mtpfw/src/cmtpconnection.cpp
branchRCL_3
changeset 2 4843bb5893b6
parent 1 f8e15b44d440
child 4 60a94a45d437
equal deleted inserted replaced
1:f8e15b44d440 2:4843bb5893b6
    91     while ((link = iter++) != NULL)
    91     while ((link = iter++) != NULL)
    92     	{
    92     	{
    93     	delete link;
    93     	delete link;
    94     	}
    94     	}
    95     
    95     
    96     if (iTransportConnection != NULL)
       
    97 	    {
       
    98 	    iTransportConnection->Unbind(*this);
       
    99 	    }
       
   100     iSessions.ResetAndDestroy();
    96     iSessions.ResetAndDestroy();
   101     //close the property
    97     //close the property
   102     iProperty.Close();
    98     iProperty.Close();
   103     // delete the ‘name?property
    99     // delete the ‘name?property
   104     RProcess process;
   100     RProcess process;
   372     {
   368     {
   373     __FLOG(_L8("CompleteCloseConnection - Entry"));
   369     __FLOG(_L8("CompleteCloseConnection - Entry"));
   374     
   370     
   375     CloseAllSessions();
   371     CloseAllSessions();
   376     iSessions.Reset();
   372     iSessions.Reset();
       
   373 	if (iTransportConnection != NULL)
       
   374 		{
       
   375 		iTransportConnection->Unbind(*this);
       
   376 		}
   377     
   377     
   378     //notify ConnectionMgr and corresponding transports of completion of connection close
   378     //notify ConnectionMgr and corresponding transports of completion of connection close
   379     iSingletons.ConnectionMgr().ConnectionCloseComplete(iConnectionId);    
   379     iSingletons.ConnectionMgr().ConnectionCloseComplete(iConnectionId);    
   380     iSingletons.Close();
   380     iSingletons.Close();
   381 
   381 
   428 
   428 
   429     if (ValidFrameworkRequest(&session, KValidPhases, NULL))
   429     if (ValidFrameworkRequest(&session, KValidPhases, NULL))
   430         {
   430         {
   431         session.SetTransactionPhase(EIdlePhase);
   431         session.SetTransactionPhase(EIdlePhase);
   432         
   432         
       
   433 		if (iTransportConnection != NULL)
       
   434             {
       
   435             iTransportConnection->TransactionCompleteL(aRequest);
       
   436             }
       
   437 			
   433         if (State() == EStateShutdown && ActiveSessions() == 0)
   438         if (State() == EStateShutdown && ActiveSessions() == 0)
   434             {     
   439             {     
   435             CompleteCloseConnection();
   440             CompleteCloseConnection();
   436             }
       
   437         
       
   438         if (iTransportConnection != NULL)
       
   439             {
       
   440             iTransportConnection->TransactionCompleteL(aRequest);
       
   441             }
   441             }
   442         }
   442         }
   443     __FLOG(_L8("TransactionCompleteL - Exit"));
   443     __FLOG(_L8("TransactionCompleteL - Exit"));
   444     }
   444     }
   445     
   445