bluetooth/btstack/linkmgr/ProxySAP.cpp
branchRCL_3
changeset 18 f8503e232b0c
parent 0 29b1cd4cb562
child 23 32ba20339036
child 32 f72906e669b4
--- a/bluetooth/btstack/linkmgr/ProxySAP.cpp	Wed Apr 14 17:08:52 2010 +0300
+++ b/bluetooth/btstack/linkmgr/ProxySAP.cpp	Tue Apr 27 17:48:21 2010 +0300
@@ -766,12 +766,12 @@
 			return;
 			}										
 
-		if (aDisconnectOption == KDisconnectAllPhysicalLinks)
+		if (aDisconnectOption == KDisconnectAllPhysicalLinks || aDisconnectOption == KDisconnectAllPhysicalLinksForPowerOff)
 			{
 			// Disconnecting All BT Physical Links
 			// Only support link *termination*, this is done as normal cos esock weirdness
 			__ASSERT_ALWAYS(aCloseType == CServProviderBase::ENormal, Panic(EBTProxySAPInvalidTerminate));
-			rerr = iLinksMan.TerminateAllPhysicalLinks(this);
+			rerr = iLinksMan.TerminateAllPhysicalLinks(this, aDisconnectOption == KDisconnectAllPhysicalLinksForPowerOff ? ERemoteAboutToPowerOff : ERemoteUserEndedConnection);
 			LOG2(_L("Proxy SAP 0x%08x -- Terminating all PHY Links, error: %d"), this, rerr);
 			
 			// If there was an error terminating any of the physical links then we can