syncmlfw/common/http/src/nsmlhttp.cpp
branchRCL_3
changeset 61 b183ec05bd8c
parent 9 57a65a3a658c
child 62 19bba8228ff0
--- a/syncmlfw/common/http/src/nsmlhttp.cpp	Thu Aug 19 10:44:50 2010 +0300
+++ b/syncmlfw/common/http/src/nsmlhttp.cpp	Tue Aug 31 16:04:06 2010 +0300
@@ -22,7 +22,6 @@
 #include <DevManInternalCRKeys.h>
 #include <centralrepository.h>
 #include "nsmlprivatepskeys.h"
-#include <nsmlconstants.h>
 
 
 #include "nsmlerror.h"
@@ -82,7 +81,6 @@
 	{
 	// construct shutdown timer
 	DBG_FILE(_S8("CNSmlHTTP::ConstructL BEGIN"));
-	TBool dmjob = EFalse;
 	FeatureManager::InitializeLibL();
 	iShutdown = new (ELeave) CNSmlXptShutdownTimer( this );
 	iShutdown->ConstructL();
@@ -93,7 +91,6 @@
     DBG_FILE_CODE(session, _S8("CNSmlHTTP::ConstructL Current Session is (DM = 2, DS = 1) "));
     if( session == ESyncMLDMSession )//for dm session
        {
-       dmjob = ETrue;
 		TInt dmsessionTimeout = -1;
 		CRepository *rep = NULL;
 		TRAPD( err1, rep = CRepository::NewL( KCRUidDeviceManagementInternalKeys ))
@@ -125,7 +122,7 @@
     RProperty::Get( KPSUidNSmlSOSServerKey, KNSmlSyncJobOngoing, iSession);                       
 	// construct dialup agent
 	iDialUpAgent = new (ELeave) CNSmlDialUpAgent();
-	iDialUpAgent->ConstructL(dmjob);
+	iDialUpAgent->ConstructL();
 
 	iEngineState = ExptIdle;
 	iTimeOut = EFalse;
@@ -146,16 +143,6 @@
             iMaxMsgSize = value;
             }
         }
-    
-    CRepository* rep = CRepository::NewLC(KCRUidNSmlDSEngine);
-    TInt flag(0);
-    TRAPD(err, rep->Get(KNsmlDsDeflateSupport, flag));
-    DBG_FILE_CODE(flag, _S8("Flag value"));
-    if ( err == KErrNone )
-        {
-        iDeflateFlag = flag;
-        }
-    CleanupStack::PopAndDestroy(rep);
 	}
 
 // ---------------------------------------------------------
@@ -578,7 +565,7 @@
 	delete iReqBodySubmitBuffer;
     iReqBodySubmitBuffer = NULL;
 	
-	if( (iSession == ESyncMLDSSession) && (iServerAcceptEncoding == ExptDeflate) && iDeflateFlag )
+	if( (iSession == ESyncMLDSSession) && (iServerAcceptEncoding == ExptDeflate) )
 		{
 		TRAPD( err, CompressL(aStartPtr) );
 		User::LeaveIfError( err );
@@ -1083,13 +1070,13 @@
 	SetHeaderL( hdr, HTTP::EAcceptCharset, KSmlAcceptCharSet );
 	SetHeaderL( hdr, HTTP::EAcceptLanguage , KSmlAcceptLanguage );
 		
-	if( iSession == ESyncMLDSSession && iDeflateFlag )//for ds session
-	  {
+	if( iSession == ESyncMLDSSession )//for ds session
+	  { 
 	  if(iServerAcceptEncoding == ExptDeflate)
-          {
-          SetHeaderL( hdr, HTTP::EContentEncoding , KSmlContentDeflate );
-          }
-          SetHeaderL( hdr, HTTP::EAcceptEncoding , KSmlContentDeflate );
+	      {
+	      SetHeaderL( hdr, HTTP::EContentEncoding , KSmlContentDeflate );
+	      }
+	      SetHeaderL( hdr, HTTP::EAcceptEncoding , KSmlContentDeflate );
 	  }
 
 	// Add headers and body data for methods that use request bodies
@@ -1148,7 +1135,7 @@
 		}
 		else
 		{
-		    if ( (iSession == ESyncMLDSSession) && (iServerContentEncoding == ExptDeflate) && iDeflateFlag )
+		    if ( (iSession == ESyncMLDSSession) && (iServerContentEncoding == ExptDeflate) )
 		        {		    
 		        TRAPD( err, DecompressL( aStartPtr ) );		    
 				User::LeaveIfError( err );