another fix from oksh for Vi Mode word erase handling, appears to unbreak
more from cid 1004A2D72DD5A4E4B4F tried to be fixed in 1004A300A72701188E3 but I’d appreciate someone who actually uses Vi Mode to test it: Revision 1.26: [7]download - view: [8]text, [9]markup, [10]annotated - [11]select for diffs Mon Jun 29 22:50:19 2009 UTC (5 days, 14 hours ago) by martynas Branches: [12]MAIN CVS tags: [13]OPENBSD_4_6_BASE, [14]OPENBSD_4_6, [15]HEAD Diff to: previous 1.25: [16]preferred, [17]coloured Changes since revision 1.25: +10 -5 lines make VSEARCH werase act like regular werase after the last change. vi back-words and emacs kill-region are not completely the same. ok merdely@, millert@. "Get it in" Darrin Chandler
This commit is contained in:
parent
5048a75ca4
commit
3ba2780eb3
4
check.t
4
check.t
@ -1,4 +1,4 @@
|
||||
# $MirOS: src/bin/mksh/check.t,v 1.288 2009/06/11 12:42:15 tg Exp $
|
||||
# $MirOS: src/bin/mksh/check.t,v 1.289 2009/07/05 13:56:46 tg Exp $
|
||||
# $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $
|
||||
# $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $
|
||||
# $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $
|
||||
@ -25,7 +25,7 @@
|
||||
# http://www.research.att.com/~gsf/public/ifs.sh
|
||||
|
||||
expected-stdout:
|
||||
@(#)MIRBSD KSH R38 2009/06/10
|
||||
@(#)MIRBSD KSH R38 2009/07/05
|
||||
description:
|
||||
Check version of shell.
|
||||
stdin:
|
||||
|
20
edit.c
20
edit.c
@ -1,7 +1,7 @@
|
||||
/* $OpenBSD: edit.c,v 1.33 2007/08/02 10:50:25 fgsch Exp $ */
|
||||
/* $OpenBSD: edit.h,v 1.8 2005/03/28 21:28:22 deraadt Exp $ */
|
||||
/* $OpenBSD: emacs.c,v 1.42 2009/06/02 06:47:47 halex Exp $ */
|
||||
/* $OpenBSD: vi.c,v 1.25 2009/06/10 15:08:46 merdely Exp $ */
|
||||
/* $OpenBSD: vi.c,v 1.26 2009/06/29 22:50:19 martynas Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2003, 2004, 2005, 2006, 2007, 2008, 2009
|
||||
@ -25,7 +25,7 @@
|
||||
|
||||
#include "sh.h"
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/edit.c,v 1.171 2009/06/11 12:42:16 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/edit.c,v 1.172 2009/07/05 13:56:47 tg Exp $");
|
||||
|
||||
/* tty driver characters we are interested in */
|
||||
typedef struct {
|
||||
@ -3871,13 +3871,17 @@ vi_hook(int ch)
|
||||
refresh(0);
|
||||
return (0);
|
||||
} else if (ch == edchars.werase) {
|
||||
int i;
|
||||
int n = srchlen;
|
||||
int i, n = srchlen;
|
||||
struct edstate new_es, *save_es;
|
||||
|
||||
new_es.cursor = n;
|
||||
new_es.cbuf = locpat;
|
||||
|
||||
save_es = es;
|
||||
es = &new_es;
|
||||
n = backword(1);
|
||||
es = save_es;
|
||||
|
||||
while (n > 0 && !ksh_isalnux(locpat[n - 1]))
|
||||
n--;
|
||||
while (n > 0 && ksh_isalnux(locpat[n - 1]))
|
||||
n--;
|
||||
for (i = srchlen; --i >= n; )
|
||||
es->linelen -= char_len((unsigned char)locpat[i]);
|
||||
srchlen = n;
|
||||
|
4
sh.h
4
sh.h
@ -122,9 +122,9 @@
|
||||
#define __SCCSID(x) __IDSTRING(sccsid,x)
|
||||
|
||||
#ifdef EXTERN
|
||||
__RCSID("$MirOS: src/bin/mksh/sh.h,v 1.310 2009/06/10 18:12:48 tg Rel $");
|
||||
__RCSID("$MirOS: src/bin/mksh/sh.h,v 1.311 2009/07/05 13:56:48 tg Exp $");
|
||||
#endif
|
||||
#define MKSH_VERSION "R38 2009/06/10"
|
||||
#define MKSH_VERSION "R38 2009/07/05"
|
||||
|
||||
#ifndef MKSH_INCLUDES_ONLY
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user