Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e458d73a authored by Chris Manton's avatar Chris Manton
Browse files

gd: Unwind futures and promises in reverse time

Bug: 171568335
Tag: #refactor
Test: atest --host bluetooth_test_gd
Change-Id: I3ff1deb2c23388b8c2114b09689ddea7380f7365
parent c94db22a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -168,8 +168,8 @@ class TestHciLayer : public HciLayer {

  ConnectionManagementCommandView GetLastCommandPacket(OpCode op_code) {
    if (!command_queue_.empty() && command_future_ != nullptr) {
      command_promise_.reset();
      command_future_.reset();
      command_promise_.reset();
    } else if (command_future_ != nullptr) {
      auto result = command_future_->wait_for(std::chrono::milliseconds(1000));
      EXPECT_NE(std::future_status::timeout, result);