OSDN Git Service

WifiStateMachine: fix for exiting L2ConnectedState
authorYuhao Zheng <yuhaozheng@google.com>
Wed, 9 Oct 2013 00:44:05 +0000 (17:44 -0700)
committerYuhao Zheng <yuhaozheng@google.com>
Wed, 9 Oct 2013 01:16:03 +0000 (18:16 -0700)
commita9e6be83aeafd6e97e5eb52e12766b476ab94da0
tree2d682a05aa2b6077ecddb0b9f366af78e9494149
parente60b7bf7f570a93cbab48e3763cb50d51ee4aa03
WifiStateMachine: fix for exiting L2ConnectedState

After a L2ConnectedState to WpsRunningState transition, network is disconnected.
However, the disconnected message is ignored by WpsRunningState, leaving DHCP
still running. When entering L2ConnectedState again, WifiStateMachine gets stuck
on waiting for DhcpStateMachine, because DHCP is already running and the command
CMD_START_DHCP is ignored. Calling handleNetworkDisconnect() when exiting
L2ConnectedState fixes this problem, plus it handles disconnection correctly.

Bug: 10900241
Change-Id: Id29e4989b29db7e64719940cf93eba1f1a90912a
wifi/java/android/net/wifi/WifiStateMachine.java