Call el_source before initializing sh-specific editline properties (i.e.
the editor type and the tab completion binding). This allows tab completion to work when a user has an ~/.editrc file. Addresses PR bin/43404.
This commit is contained in:
parent
dac028c1ff
commit
416c5b0ff8
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: histedit.c,v 1.41 2008/02/13 12:57:16 joerg Exp $ */
|
||||
/* $NetBSD: histedit.c,v 1.42 2011/01/07 22:21:56 jmmv Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1993
|
||||
|
@ -37,7 +37,7 @@
|
|||
#if 0
|
||||
static char sccsid[] = "@(#)histedit.c 8.2 (Berkeley) 5/4/95";
|
||||
#else
|
||||
__RCSID("$NetBSD: histedit.c,v 1.41 2008/02/13 12:57:16 joerg Exp $");
|
||||
__RCSID("$NetBSD: histedit.c,v 1.42 2011/01/07 22:21:56 jmmv Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
|
@ -149,13 +149,13 @@ bad:
|
|||
INTON;
|
||||
}
|
||||
if (el) {
|
||||
el_source(el, NULL);
|
||||
if (Vflag)
|
||||
el_set(el, EL_EDITOR, "vi");
|
||||
else if (Eflag)
|
||||
el_set(el, EL_EDITOR, "emacs");
|
||||
el_set(el, EL_BIND, "^I",
|
||||
tabcomplete ? "rl-complete" : "ed-insert", NULL);
|
||||
el_source(el, NULL);
|
||||
}
|
||||
} else {
|
||||
INTOFF;
|
||||
|
|
Loading…
Reference in New Issue