summaryrefslogtreecommitdiff
path: root/sshkey-xmss.c
diff options
context:
space:
mode:
Diffstat (limited to 'sshkey-xmss.c')
-rw-r--r--sshkey-xmss.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sshkey-xmss.c b/sshkey-xmss.c
index 5d66ee790350..aaae7028928c 100644
--- a/sshkey-xmss.c
+++ b/sshkey-xmss.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshkey-xmss.c,v 1.1 2018/02/23 15:58:38 markus Exp $ */
+/* $OpenBSD: sshkey-xmss.c,v 1.3 2018/07/09 21:59:10 markus Exp $ */
/*
* Copyright (c) 2017 Markus Friedl. All rights reserved.
*
@@ -66,7 +66,7 @@ struct ssh_xmss_state {
treehash_inst *treehash;
u_int32_t idx; /* state read from file */
- u_int32_t maxidx; /* resticted # of signatures */
+ u_int32_t maxidx; /* restricted # of signatures */
int have_state; /* .state file exists */
int lockfd; /* locked in sshkey_xmss_get_state() */
int allow_update; /* allow sshkey_xmss_update_state() */
@@ -583,7 +583,7 @@ sshkey_xmss_update_state(const struct sshkey *k, sshkey_printfn *pr)
}
idx = PEEK_U32(k->xmss_sk);
if (idx == state->idx) {
- /* no signature happend, no need to update */
+ /* no signature happened, no need to update */
ret = 0;
goto done;
} else if (idx != state->idx + 1) {
@@ -625,7 +625,7 @@ sshkey_xmss_update_state(const struct sshkey *k, sshkey_printfn *pr)
close(fd);
goto done;
}
- if (atomicio(vwrite, fd, (void *)sshbuf_ptr(enc), sshbuf_len(enc)) !=
+ if (atomicio(vwrite, fd, sshbuf_mutable_ptr(enc), sshbuf_len(enc)) !=
sshbuf_len(enc)) {
ret = SSH_ERR_SYSTEM_ERROR;
PRINT("%s: write new state file data: %s", __func__, nstatefile);