aboutsummaryrefslogtreecommitdiff
path: root/nitrokey/src/auth.rs
diff options
context:
space:
mode:
authorDaniel Mueller <deso@posteo.net>2019-01-05 16:04:49 -0800
committerDaniel Mueller <deso@posteo.net>2019-01-05 16:04:49 -0800
commitd9adac05dfa5de83465fde3479df4fd898ebd8bd (patch)
tree3bcb5585b4f821250276d6bf1eadd05f1748d016 /nitrokey/src/auth.rs
parentbbb54f26c6101225a4f79f2f7f89cf5d71a62dd1 (diff)
downloadnitrocli-d9adac05dfa5de83465fde3479df4fd898ebd8bd.tar.gz
nitrocli-d9adac05dfa5de83465fde3479df4fd898ebd8bd.tar.bz2
Update nitrokey crate to 0.3.0
This change updates the nitrokey crate to version 0.3.0. Import subrepo nitrokey/:nitrokey at 3593df8844b80741e2d33c8e5af80e65760dc058
Diffstat (limited to 'nitrokey/src/auth.rs')
-rw-r--r--nitrokey/src/auth.rs5
1 files changed, 1 insertions, 4 deletions
diff --git a/nitrokey/src/auth.rs b/nitrokey/src/auth.rs
index 017cdbb..a129bd8 100644
--- a/nitrokey/src/auth.rs
+++ b/nitrokey/src/auth.rs
@@ -149,10 +149,7 @@ where
A: AuthenticatedDevice<D>,
T: Fn(*const i8, *const i8) -> c_int,
{
- let temp_password = match generate_password(TEMPORARY_PASSWORD_LENGTH) {
- Ok(pw) => pw,
- Err(_) => return Err((device, CommandError::RngError)),
- };
+ let temp_password = generate_password(TEMPORARY_PASSWORD_LENGTH);
let password = match get_cstring(password) {
Ok(password) => password,
Err(err) => return Err((device, err)),