telephonyserverplugins/common_tsy/commontsy/src/mmtsy/cmmconferencecalltsy.cpp
branchRCL_3
changeset 16 fe8b59ab9fa0
parent 0 3553901f7fa8
child 24 6638e7f4bd8f
child 42 3adadc800673
equal deleted inserted replaced
15:fc69e1e37771 16:fe8b59ab9fa0
    30 #include <etelmmerr.h> // etel error codes
    30 #include <etelmmerr.h> // etel error codes
    31 
    31 
    32 
    32 
    33 // ======== MEMBER FUNCTIONS ========
    33 // ======== MEMBER FUNCTIONS ========
    34 
    34 
    35 CMmConferenceCallTsy::CMmConferenceCallTsy()
    35 CMmConferenceCallTsy::CMmConferenceCallTsy():
       
    36     iReqHandleType(EMultimodeConferenceCallReqHandleUnknown)
    36     {
    37     {
    37     }
    38     }
    38     
    39     
    39 CMmConferenceCallTsy* CMmConferenceCallTsy::NewL(
    40 CMmConferenceCallTsy* CMmConferenceCallTsy::NewL(
    40     CMmPhoneTsy* aMmPhone )
    41     CMmPhoneTsy* aMmPhone )
   174     const TDataPackage& aPackage )
   175     const TDataPackage& aPackage )
   175     {
   176     {
   176     TInt ret( KErrNone );
   177     TInt ret( KErrNone );
   177     TInt trapError( KErrNone );
   178     TInt trapError( KErrNone );
   178 
   179 
   179     //reset last tsy request type
   180     // Ensure the ReqHandleType is unset.
   180     iReqHandleType = EMultimodeConferenceCallReqHandleUnknown;
   181     // This will detect cases where this method indirectly calls itself
       
   182     // (e.g. servicing a client call that causes a self-reposting notification to complete and thus repost).
       
   183     // Such cases are not supported because iReqHandleType is in the context of this class instance,
       
   184     // not this request, and we don't want the values set by the inner request and the outer request
       
   185     // interfering with each other.
       
   186     __ASSERT_DEBUG(iReqHandleType==EMultimodeConferenceCallReqHandleUnknown, User::Invariant());
   181 
   187 
   182     //Original code continues here.
   188     //Original code continues here.
   183     TRAP( trapError, ret = DoExtFuncL( aTsyReqHandle, aIpc, aPackage ); );
   189     TRAP( trapError, ret = DoExtFuncL( aTsyReqHandle, aIpc, aPackage ); );
   184 
   190 
   185     if ( trapError != KErrNone )
   191     if ( trapError != KErrNone )
   200 #ifdef REQHANDLE_TIMER
   206 #ifdef REQHANDLE_TIMER
   201         SetTypeOfResponse ( iReqHandleType, aTsyReqHandle );
   207         SetTypeOfResponse ( iReqHandleType, aTsyReqHandle );
   202 #else
   208 #else
   203         iTsyReqHandleStore->SetTsyReqHandle( iReqHandleType, aTsyReqHandle );
   209         iTsyReqHandleStore->SetTsyReqHandle( iReqHandleType, aTsyReqHandle );
   204 #endif
   210 #endif
       
   211         // We've finished with this value now. Clear it so it doesn't leak
       
   212         //  up to any other instances of this method down the call stack
       
   213         iReqHandleType = EMultimodeConferenceCallReqHandleUnknown;
   205         }
   214         }
   206 
   215 
   207     return KErrNone;
   216     return KErrNone;
   208 
   217 
   209     }
   218     }
  1594     iAddCallName.Zero();
  1603     iAddCallName.Zero();
  1595     //Conference call capabilities
  1604     //Conference call capabilities
  1596     iConferenceCaps = 0;
  1605     iConferenceCaps = 0;
  1597     //Number of calls in conference call
  1606     //Number of calls in conference call
  1598     iNumOfCallsInConferenceCall = 0;
  1607     iNumOfCallsInConferenceCall = 0;
  1599     //Last used req handle type
       
  1600     iReqHandleType = EMultimodeConferenceCallReqHandleUnknown;
       
  1601     //Conference call status
  1608     //Conference call status
  1602     iStatus = RMobileConferenceCall::EConferenceIdle;
  1609     iStatus = RMobileConferenceCall::EConferenceIdle;
  1603     //Reset pointer
  1610     //Reset pointer
  1604     iHoldCall = NULL;
  1611     iHoldCall = NULL;
  1605 	//Reset pointer
  1612 	//Reset pointer