rtp/srtpstack/tsrc/ut_srtpstack/src/UT_CSRTPStreamIn.cpp
branchRCL_3
changeset 43 b5e99d8877c7
parent 0 307788aac0a8
child 44 0dcb073356a5
--- a/rtp/srtpstack/tsrc/ut_srtpstack/src/UT_CSRTPStreamIn.cpp	Thu Aug 19 10:16:25 2010 +0300
+++ b/rtp/srtpstack/tsrc/ut_srtpstack/src/UT_CSRTPStreamIn.cpp	Tue Aug 31 15:32:57 2010 +0300
@@ -347,11 +347,19 @@
     {
     delete iDecryptedPayload;
     delete iTestPayload160Bits;
+	
+	iDecryptedPayload = NULL;
+    iTestPayload160Bits = NULL;
+
 
 
     delete iStreamIn;
     delete iStreamInLateBD;
     delete iSRTPSession;    
+	
+	iStreamIn = NULL;
+    iStreamInLateBD = NULL;
+    iSRTPSession = NULL; 
 
    
     delete iRFC3711_SessionEncrKey128bits;
@@ -360,16 +368,23 @@
     delete iRFC3711_RtcpEncrKey128bits;
 	delete iRFC3711_RtcpSaltKey128bits;
 	delete iRFC3711_RtcpAuthKey128bits;
+	
+	iRFC3711_SessionEncrKey128bits = NULL;
+    iRFC3711_SessionSaltKey128bits = NULL;
+    iRFC3711_SessionAuthKey128bits = NULL;    
+    iRFC3711_RtcpEncrKey128bits = NULL;
+	iRFC3711_RtcpSaltKey128bits = NULL;
+	iRFC3711_RtcpAuthKey128bits = NULL;
     }
 
-void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_1L(  )
+void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_OneL(  )
     {        
     CSRTPStreamIn* tempStreamIn = CSRTPStreamIn::NewL(*iSRTPSession, (TUint)1);
     EUNIT_ASSERT(tempStreamIn->SSRC()== 1);
     delete tempStreamIn;
     }
 
-void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_2L(  )
+void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_TwoL(  )
     {
     HBufC8* masterKey = HBufC8::NewL(KRFC3711_TestMasterKey128bits().Length());
     CleanupStack::PushL( masterKey );
@@ -406,7 +421,7 @@
      CleanupStack::PopAndDestroy( srtpSession );                   
     }
 
-void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_3L(  )
+void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_ThreeL(  )
     {
     HBufC8* masterKey = HBufC8::NewL(KRFC3711_TestMasterKey128bits().Length());
     CleanupStack::PushL( masterKey );
@@ -442,7 +457,7 @@
     delete tempStreamIn;   
     CleanupStack::PopAndDestroy( srtpSession );                   
     }
-void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_4L(  )
+void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_FourL(  )
     {
      HBufC8* masterKey = HBufC8::NewL(KRFC3711_TestMasterKey128bits().Length());
     CleanupStack::PushL( masterKey );
@@ -479,7 +494,7 @@
     CleanupStack::PopAndDestroy( srtpSession );
     }
     
-void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_5L(  )
+void UT_CSRTPStreamIn::UT_CSRTPStreamIn_NewL_FiveL(  )
     {
      HBufC8* masterKey = HBufC8::NewL(KRFC3711_TestMasterKey128bits().Length());
     CleanupStack::PushL( masterKey );
@@ -1036,35 +1051,35 @@
     "CSRTPStreamIn",
     "NewL1",
     "FUNCTIONALITY",
-    SetupL, UT_CSRTPStreamIn_NewL_1L, Teardown)
+    SetupL, UT_CSRTPStreamIn_NewL_OneL, Teardown)
 
 EUNIT_TEST(
     "NewL2 - test ",
     "CSRTPStreamIn",
     "NewL2",
     "FUNCTIONALITY",
-    SetupL, UT_CSRTPStreamIn_NewL_2L, Teardown)
+    SetupL, UT_CSRTPStreamIn_NewL_TwoL, Teardown)
 
 EUNIT_TEST(
     "NewL3 - test ",
     "CSRTPStreamIn",
     "NewL3",
     "FUNCTIONALITY",
-    SetupL, UT_CSRTPStreamIn_NewL_3L, Teardown)
+    SetupL, UT_CSRTPStreamIn_NewL_ThreeL, Teardown)
     
 EUNIT_TEST(
     "NewL4 - test ",
     "CSRTPStreamIn",
     "NewL4",
     "FUNCTIONALITY",
-    SetupL, UT_CSRTPStreamIn_NewL_4L, Teardown)    
+    SetupL, UT_CSRTPStreamIn_NewL_FourL, Teardown)    
 
 EUNIT_TEST(
     "NewL5 - test ",
     "CSRTPStreamIn",
     "NewL5",
     "FUNCTIONALITY",
-    SetupL, UT_CSRTPStreamIn_NewL_5L, Teardown)    
+    SetupL, UT_CSRTPStreamIn_NewL_FiveL, Teardown)    
 EUNIT_TEST(
     "UnprotectSrtpL - test ",
     "CSRTPStreamIn",