syncmlfw/common/http/src/nsmlhttpclient.cpp
branchRCL_3
changeset 18 2de6635c154b
parent 5 3f7d9dbe57c8
child 25 b183ec05bd8c
--- a/syncmlfw/common/http/src/nsmlhttpclient.cpp	Tue May 11 16:59:53 2010 +0300
+++ b/syncmlfw/common/http/src/nsmlhttpclient.cpp	Tue May 25 13:36:17 2010 +0300
@@ -19,6 +19,9 @@
 #include "nsmlhttpclient.h"
 #include "nsmlerror.h"
 #include <featmgr.h>
+#include "NsmlOperatorErrorCRKeys.h"
+#include <centralrepository.h> 
+
 
 //Fix to Remove the Bad Compiler Warnings
 #ifndef __WINS__
@@ -129,10 +132,21 @@
 				status = CNSmlHTTP::SetErrorStatus( status );
 				
 				if (status == resp.StatusCode() )
-				{
-					DBG_FILE( _S8("Error in Communication string is set"));
-					status = TNSmlError::ESmlCommunicationInterrupted;
-				}
+				    {
+                    if( this->iAgent->iSession == ESyncMLDSSession )
+                        {
+                        CRepository* rep = NULL;
+                        TRAPD ( err, rep = CRepository::NewL( KCRUidOperatorDatasyncErrorKeys ) );
+                        if ( err == KErrNone )
+                            {
+                            rep->Set( KNsmlOpDsErrorCode, status );
+                            delete rep;
+                            }
+                        }  
+
+                    DBG_FILE( _S8("Error in Communication string is set"));
+                    status = TNSmlError::ESmlCommunicationInterrupted;
+				    }
 					
 				// content mismatch
 				aTransaction.Close();