mmappcomponents/playbackhelper/src/streaminglinkmodel.cpp
branchRCL_3
changeset 56 63223d4fd956
parent 55 6c1dfe4da5dd
child 59 666f9a5a90a9
--- a/mmappcomponents/playbackhelper/src/streaminglinkmodel.cpp	Tue Aug 31 15:41:40 2010 +0300
+++ b/mmappcomponents/playbackhelper/src/streaminglinkmodel.cpp	Wed Sep 01 12:23:05 2010 +0100
@@ -15,7 +15,7 @@
 *
 */
 
-// Version : %version: 4.1.1 %
+// Version : %version: 4 %
 
 
 
@@ -559,8 +559,6 @@
 
     TInt size = 0;
     TInt result = KErrNone;
-    
-    TBool linkadded = EFalse;
 
     if ( aRamFile.Size( size ) == KErrNone && size <= KMaxLinkFileSize )
     {
@@ -578,8 +576,6 @@
         // Get links from buffer
         while ( ret == KErrNone )
         {
-            linkadded = EFalse;
-        
             // Create a linkitem ptr
             LinkStruct* linkItem = new( ELeave ) LinkStruct;   
             CleanupStack::PushL( linkItem );
@@ -597,23 +593,14 @@
                 {
                     ptr2.TrimRight();
                     iLinkArray.Append( linkItem );
-                    linkadded = ETrue;
                 }
             }
             else
             {
                 iLinkArray.Append( linkItem );
-                linkadded = ETrue;
             }
             
-            if ( linkadded )
-            {
-                CleanupStack::Pop(2); // pop the linkItem and the HbufC created for linkItem->link               
-            }                              
-            else 
-            {
-                CleanupStack::PopAndDestroy(2); //pop and destroy linkItem and the HbufC created for linkItem->link
-            }
+            CleanupStack::Pop(2); // pop the linkItem and the HbufC created for linkItem->link
         }
 
         CleanupStack::PopAndDestroy(2);  // buffer, recognizer
@@ -649,8 +636,6 @@
     iLinkCount = 0;
 
     TInt ret = KErrNone;
-    
-    TBool linkadded = EFalse;
 
     if ( aAsxParser )
     {
@@ -665,9 +650,6 @@
 
             for (TInt i=1; i <= urlCount; i++)
             {
-
-                linkadded = EFalse;
-                
                 // Get the asx struct from the parser
                 asxItem = aAsxParser->GetUrl(i);
                 // Set the url to the bufferptr
@@ -695,23 +677,15 @@
                     {
                         ptr2.TrimRight();
                         iLinkArray.Append( linkItem );
-                        linkadded = ETrue;
                     }
                 }
                 else
                 {
                     iLinkArray.Append( linkItem );
-                    linkadded = ETrue;
                 }
-                                              
-                if ( linkadded )
-                {
-                    CleanupStack::Pop(2); // pop the linkItem and the HbufC created for linkItem->link                    
-                }                              
-                else 
-                {
-                    CleanupStack::PopAndDestroy(2); //pop and destroy linkItem and the HbufC created for linkItem->link
-                }
+                
+                CleanupStack::Pop(2); // pop the linkItem and the HbufC created for linkItem->link 
+
             }
 
             CleanupStack::PopAndDestroy();  //recognizer