summaryrefslogtreecommitdiffstats
path: root/cmd-list-keys.c
diff options
context:
space:
mode:
authorTiago Cunha <tcunha@gmx.com>2010-10-24 01:31:57 +0000
committerTiago Cunha <tcunha@gmx.com>2010-10-24 01:31:57 +0000
commit2da0730f78ba3f96eba98584d08fba1a98a1ca60 (patch)
tree8be8157c9b529a37cd75103d203f510bd249c408 /cmd-list-keys.c
parentbdbd4e28c2c3cbf6c1372bee50a7ea26b32d7041 (diff)
Sync OpenBSD patchset 778:
Mark repeating keys with "(repeat)" in the key list.
Diffstat (limited to 'cmd-list-keys.c')
-rw-r--r--cmd-list-keys.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/cmd-list-keys.c b/cmd-list-keys.c
index 80845211..82cc24f8 100644
--- a/cmd-list-keys.c
+++ b/cmd-list-keys.c
@@ -1,4 +1,4 @@
-/* $Id: cmd-list-keys.c,v 1.24 2009-12-04 22:14:47 tcunha Exp $ */
+/* $Id: cmd-list-keys.c,v 1.25 2010-10-24 01:31:57 tcunha Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -80,6 +80,11 @@ cmd_list_keys_exec(struct cmd *self, struct cmd_ctx *ctx)
if (used >= sizeof tmp)
continue;
}
+ if (bd->can_repeat) {
+ used = strlcat(tmp, "(repeat) ", sizeof tmp);
+ if (used >= sizeof tmp)
+ continue;
+ }
cmd_list_print(bd->cmdlist, tmp + used, (sizeof tmp) - used);
ctx->print(ctx, "%s", tmp);
}