Merge "adbd: avoid starting multiple worker threads." am: 5ddd49eeae

am: dcfc785d20

Change-Id: Id5fbaba786214b2d5b9dcab7f433ce12f850d35d
This commit is contained in:
Josh Gao 2019-05-02 14:33:26 -07:00 committed by android-build-merger
commit d594359e7f
1 changed files with 4 additions and 0 deletions

View File

@ -310,11 +310,13 @@ struct UsbFfsConnection : public Connection {
if (bound) {
LOG(WARNING) << "received FUNCTIONFS_BIND while already bound?";
running = false;
break;
}
if (enabled) {
LOG(WARNING) << "received FUNCTIONFS_BIND while already enabled?";
running = false;
break;
}
bound = true;
@ -324,11 +326,13 @@ struct UsbFfsConnection : public Connection {
if (!bound) {
LOG(WARNING) << "received FUNCTIONFS_ENABLE while not bound?";
running = false;
break;
}
if (enabled) {
LOG(WARNING) << "received FUNCTIONFS_ENABLE while already enabled?";
running = false;
break;
}
enabled = true;