| 91 | } |
| 92 | |
| 93 | void MockDeviceBridge::Send(ByteView blob) |
| 94 | { |
| 95 | auto sender = GetChunkSender(blob); |
| 96 | for (auto noProgressCounter = 0; noProgressCounter < 10; ++noProgressCounter) |
| 97 | { |
| 98 | if (sender.Send()) |
| 99 | noProgressCounter = 0; |
| 100 | |
| 101 | if (sender.IsDone()) |
| 102 | return; |
| 103 | } |
| 104 | |
| 105 | throw std::runtime_error("Cannot send data"); |
| 106 | } |
| 107 | |
| 108 | std::vector<FSecure::ByteVector> MockDeviceBridge::Receive(size_t minExpectedSize) |
| 109 | { |