diff options
author | Szczepan Zalega <szczepan@nitrokey.com> | 2016-07-28 14:39:27 +0200 |
---|---|---|
committer | Szczepan Zalega <szczepan@nitrokey.com> | 2016-08-01 13:54:58 +0200 |
commit | 794e6da41ba22dc7c7294da52a8d5f448820525d (patch) | |
tree | 5874129f949a5677b3bade82570a1cca5c10f6c9 /include/device_proto.h | |
parent | 470750a93c181e01a761dd15f718a3256e4ce3be (diff) | |
download | libnitrokey-794e6da41ba22dc7c7294da52a8d5f448820525d.tar.gz libnitrokey-794e6da41ba22dc7c7294da52a8d5f448820525d.tar.bz2 |
Set different delay timings for Nitrokey Storage
Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
Diffstat (limited to 'include/device_proto.h')
-rw-r--r-- | include/device_proto.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/device_proto.h b/include/device_proto.h index c248b10..82606a1 100644 --- a/include/device_proto.h +++ b/include/device_proto.h @@ -165,6 +165,7 @@ class Transaction : semantics::non_constructible { const command_payload &payload) { using namespace ::nitrokey::device; using namespace ::nitrokey::log; + using namespace std::chrono_literals; Log::instance()(__PRETTY_FUNCTION__, Loglevel::DEBUG_L2); @@ -190,7 +191,9 @@ class Transaction : semantics::non_constructible { std::string("Device error while sending command ") + std::to_string((int)(status))); - // FIXME make checks done in device:recv here + std::this_thread::sleep_for(1000ms); + + // FIXME make checks done in device:recv here int retry = dev.get_retry_count(); while (retry-- > 0) { status = dev.recv(&resp); |