[bt][a2dp-sink] Detect socket close on AVDTP close

When a peer sent us a close signal, a 3 second timer would wait for the
peer to close the transport (as in AVDTP spec section 6.3) before
checking.

Instead complete the operation when the peer disconnects the transport
socket.

This mitigates a race condition where the a2dp-sink could mistakenly
add a second RemotePeer tracking the same peer while in the wait, and
that new peer would be removed, causing a panic when the peer couldn't
be found when it sent commands.

Test: connect to bt-a2dp-sink from android, reconnect quickly
BT-730 #done

Change-Id: Ia4adeced5e49c225228bbd0ba5314021203e5034
2 files changed
tree: 899a8d3067869d922ae9321ee3ae683e8e89f393
  1. boards/
  2. build/
  3. buildtools/
  4. bundles/
  5. docs/
  6. examples/
  7. garnet/
  8. peridot/
  9. products/
  10. scripts/
  11. sdk/
  12. src/
  13. third_party/
  14. tools/
  15. zircon/
  16. .clang-format
  17. .dir-locals.el
  18. .gitattributes
  19. .gitignore
  20. .gn
  21. AUTHORS
  22. BUILD.gn
  23. CODE_OF_CONDUCT.md
  24. CONTRIBUTING.md
  25. LICENSE
  26. OWNERS
  27. PATENTS
  28. README.md
  29. rustfmt.toml
README.md

Fuchsia

Pink + Purple == Fuchsia (a new operating system)

What is Fuchsia?

Fuchsia is a modular, capability-based operating system. Fuchsia runs on modern 64-bit Intel and ARM processors.

Fuchsia is an open source project with a code of conduct that we expect everyone who interacts with the project to respect.

How can I build and run Fuchsia?

See Getting Started.

Where can I learn more about Fuchsia?

See the documentation.