knet_vty_delete_backward_char(vty);
}
+static void knet_vty_forward_kill_word(struct knet_vty *vty)
+{
+ while(vty->cursor_pos != vty->line_idx && vty->line[vty->cursor_pos] == ' ')
+ knet_vty_delete_char(vty);
+
+ while(vty->cursor_pos != vty->line_idx && vty->line[vty->cursor_pos] != ' ')
+ knet_vty_delete_backward_char(vty);
+}
+
static int knet_vty_process_buf(struct knet_vty *vty, unsigned char *buf, int buflen)
{
int i;
break;
case 'd':
vty->escape = VTY_NORMAL;
- log_info("forward kill word");
+ knet_vty_forward_kill_word(vty);
break;
case CONTROL('H'):
case 0x7f: