commit | 79c5214e31471e75d79f50b6a282eebe76d2609b | [log] [tgz] |
---|---|---|
author | Kenneth Tateno <ktateno@nvidia.com> | Mon Mar 10 14:37:30 2014 -0700 |
committer | Sanjay Singh Chauhan <schauhan@nvidia.com> | Thu Apr 03 17:08:42 2014 +0530 |
tree | 018a679b758d6cc553a538915f9307862b5a0f64 | |
parent | 57abed1d8463b20a28745894d99942bfa9512e1b [diff] |
system: netd: prevent infinite loop There is a corner case where rescan() runs between allocateServiceRef and startMonitoring. After allocateServiceRef is called the node at mHead has mReady = 0. Then when rescan runs, it loops forver waiting for mReady != 0, but startMonitoring can't run because rescan has the lock. To prevent this, allow rescan to continue to the next node if mReady == 0. Change-Id: I7538e00087c02cd6b5553c992bd3c14e1a867a99