aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--termkey.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/termkey.c b/termkey.c
index 59b1859..c4ee594 100644
--- a/termkey.c
+++ b/termkey.c
@@ -1132,7 +1132,7 @@ char *termkey_strpkey(TermKey *tk, const char *str, TermKeyKey *key, TermKeyForm
key->type = TERMKEY_TYPE_KEYSYM;
str = endstr;
}
- else if(sscanf(str, "F%d%n", &key->code.number, &nbytes) == 1) {
+ else if(sscanf(str, "F%d%zn", &key->code.number, &nbytes) == 1) {
key->type = TERMKEY_TYPE_FUNCTION;
str += nbytes;
}