locationtriggering/ltclientlib/src/lbtserver.cpp
changeset 51 111f80460dbe
parent 0 667063e416a2
--- a/locationtriggering/ltclientlib/src/lbtserver.cpp	Thu Sep 02 20:51:33 2010 +0300
+++ b/locationtriggering/ltclientlib/src/lbtserver.cpp	Mon Oct 04 00:45:15 2010 +0300
@@ -70,7 +70,7 @@
 		    if( ret != KErrNone )
 		        {
 		        lbtServer.Close();
-		        return KErrNotFound;
+		        return ret;
 		        }
 		    
 		    TRequestStatus status;
@@ -90,11 +90,13 @@
 
 		    User::WaitForRequest(status);
 		    lbtServer.Close();
+		    ret = status.Int();
 
-		    if( status != KErrNone )
+		    if( !( ret == KErrNone || ret == KErrAlreadyExists ) )
 		        {
-		        return (status.Int());
+		        return ret;
 		        }
+
 		    ret = CreateSession(KLbtServerCoreName, Version(), KDefaultMessageSlots);		    
 		    }
         }