send connection broadcast on client disconnect

Bug: 7188646
Change-Id: I69f2c2581004b08730407930fb056cc1fe54feec
This commit is contained in:
Irfan Sheriff
2012-09-18 12:39:22 -07:00
parent e0c28d5f13
commit 5ef9c59fff

View File

@@ -1323,6 +1323,11 @@ public class WifiP2pService extends IWifiP2pManager.Stub {
if (!mAutonomousGroup && mGroup.isClientListEmpty()) {
Slog.d(TAG, "Client list empty, remove non-persistent p2p group");
mWifiNative.p2pGroupRemove(mGroup.getInterface());
// We end up sending connection changed broadcast
// when this happens at exit()
} else {
// Notify when a client disconnects from group
sendP2pConnectionChangedBroadcast();
}
} else {
if (DBG) logd("Failed to remove client " + deviceAddress);