supl/locationomasuplprotocolhandler/protocolhandlerver2/src/epos_comasuplprotocolmanager2.cpp
changeset 25 73f6c2762ffe
parent 22 4c4ed41530db
child 39 3efc7a0e8755
--- a/supl/locationomasuplprotocolhandler/protocolhandlerver2/src/epos_comasuplprotocolmanager2.cpp	Fri May 14 16:17:02 2010 +0300
+++ b/supl/locationomasuplprotocolhandler/protocolhandlerver2/src/epos_comasuplprotocolmanager2.cpp	Thu May 27 13:18:17 2010 +0300
@@ -108,13 +108,21 @@
 		{
 			iSettingsLauncher->CancelLaunch();
 		}*/
-	iSuplSettings->SetUIActive( EFalse );
+	
+	if(iSuplSettings)
+		{
+		iSuplSettings->SetUIActive( EFalse );
+		}
 
 	DeleteAllSessions();
 	iSuplSessions.Reset();
 	iSuplSessions.Close();
 
+	//Only attempt to unload the phone if the TSY has actually been initialised
+	if(iTsyName.Length() > 0)
+		{
 	    iTelServer.UnloadPhoneModule(iTsyName);
+		}
 
 	
 	iQueuedPacket.Close();