webservices/wsoviplugin/src/wsoviservicesession.cpp
branchRCL_3
changeset 11 6abf3d6055cd
parent 1 272b002df977
child 19 9e96e2676219
--- a/webservices/wsoviplugin/src/wsoviservicesession.cpp	Fri Feb 19 23:55:35 2010 +0200
+++ b/webservices/wsoviplugin/src/wsoviservicesession.cpp	Mon Mar 15 12:44:52 2010 +0200
@@ -588,6 +588,7 @@
 
 void CWSOviServiceSession::AdaptEndpointL(TBool aToOrginal)
     {
+    TLSLOG_L(KSenCoreServiceManagerLogChannelBase,KMinLogLevel ,"CWSOviServiceSession::AdaptEndpointL");	
     TPtrC8 oldEndpoint = Endpoint();
     if (aToOrginal)
         {
@@ -633,11 +634,16 @@
                                   +oldEndpoint.Length());
             TPtr8 ptrNewEp = newEp->Des();
             ptrNewEp.Append(oldEndpoint);
-            ptrNewEp.Append(suffixEndpoint);
+            TInt retVal = oldEndpoint.Find(suffixEndpoint);
+            if(retVal == KErrNotFound)
+            	{
+            	ptrNewEp.Append(suffixEndpoint);
+            	}
             SetEndPointL(*newEp);
             CleanupStack::PopAndDestroy(newEp);
             }
         }
+    TLSLOG_L(KSenCoreServiceManagerLogChannelBase,KMinLogLevel ,"CWSOviServiceSession::AdaptEndpointL Completed");
     }
 CSenIdentityProvider* CWSOviServiceSession::IdentityProviderFromCoreL(
                                             const TDesC8& aProviderID)