diff options
author | 2009-06-04 14:24:49 +0000 | |
---|---|---|
committer | 2009-06-04 14:24:49 +0000 | |
commit | ee5252fa9f59c1b55591c63569aeed0064911ba7 (patch) | |
tree | 5fe9fc8a9850b55621bc9fdaaca802e748abd3ab | |
parent | More input compatibility love. Support C0 within escape sequences, and the C0 (diff) | |
download | wireguard-openbsd-ee5252fa9f59c1b55591c63569aeed0064911ba7.tar.xz wireguard-openbsd-ee5252fa9f59c1b55591c63569aeed0064911ba7.zip |
Oops, CAN and SUB should abort the sequence (return to first state), not remain
in the same state.
-rw-r--r-- | usr.bin/tmux/input.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/usr.bin/tmux/input.c b/usr.bin/tmux/input.c index a4557838aca..d5bf0900a75 100644 --- a/usr.bin/tmux/input.c +++ b/usr.bin/tmux/input.c @@ -1,4 +1,4 @@ -/* $OpenBSD: input.c,v 1.4 2009/06/04 14:15:50 nicm Exp $ */ +/* $OpenBSD: input.c,v 1.5 2009/06/04 14:24:49 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -400,6 +400,9 @@ input_state_sequence_first(u_char ch, struct input_ctx *ictx) /* Abort sequence and begin with new. */ input_state(ictx, input_state_escape); } else if (ch != 0x18 && ch != 0x1a) { /* CAN and SUB */ + /* Abort sequence. */ + input_state(ictx, input_state_first); + } else { /* Handle C0 immediately. */ input_handle_c0_control(ch, ictx); } @@ -465,6 +468,9 @@ input_state_sequence_next(u_char ch, struct input_ctx *ictx) /* Abort sequence and begin with new. */ input_state(ictx, input_state_escape); } else if (ch != 0x18 && ch != 0x1a) { /* CAN and SUB */ + /* Abort sequence. */ + input_state(ictx, input_state_first); + } else { /* Handle C0 immediately. */ input_handle_c0_control(ch, ictx); } |