From 73669f1b035317a324123a7e0c840dc59bbb961b Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Sat, 20 Nov 2010 11:20:48 +0200 Subject: [PATCH] edit: Fix Home/End escape codes --- src/utils/edit.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/utils/edit.c b/src/utils/edit.c index f080b09c0..62ba0e135 100644 --- a/src/utils/edit.c +++ b/src/utils/edit.c @@ -456,12 +456,6 @@ static void edit_read_char(int sock, void *eloop_ctx, void *sock_ctx) case 'D': /* left */ move_left(); break; - case 'F': /* end */ - move_end(); - break; - case 'H': /* home */ - move_start(); - break; default: printf("{ESC%s}[1]\n", esc_buf); edit_redraw(); @@ -533,6 +527,12 @@ static void edit_read_char(int sock, void *eloop_ctx, void *sock_ctx) if (esc > 1 && esc_buf[0] == 'O') { switch (esc_buf[1]) { + case 'F': /* end */ + move_end(); + break; + case 'H': /* home */ + move_start(); + break; case 'P': /* F1 */ history_debug_dump(); break;