From 90692e8243d9334f92182299ee401dc0a90965e2 Mon Sep 17 00:00:00 2001 From: pfg Date: Mon, 20 Feb 2017 03:33:59 +0000 Subject: MFC r312997, r313002: Re-import libedit 2016-02-27 and update libedit with changes from NetBSD's 2016-03-21. Obtained from: NetBSD --- lib/libedit/parse.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'lib/libedit/parse.c') diff --git a/lib/libedit/parse.c b/lib/libedit/parse.c index 1c19cc7..1b7bdb4 100644 --- a/lib/libedit/parse.c +++ b/lib/libedit/parse.c @@ -1,4 +1,4 @@ -/* $NetBSD: parse.c,v 1.27 2014/07/06 18:15:34 christos Exp $ */ +/* $NetBSD: parse.c,v 1.35 2016/02/17 19:47:49 christos Exp $ */ /*- * Copyright (c) 1992, 1993 @@ -37,7 +37,7 @@ #if 0 static char sccsid[] = "@(#)parse.c 8.1 (Berkeley) 6/4/93"; #else -__RCSID("$NetBSD: parse.c,v 1.27 2014/07/06 18:15:34 christos Exp $"); +__RCSID("$NetBSD: parse.c,v 1.35 2016/02/17 19:47:49 christos Exp $"); #endif #endif /* not lint && not SCCSID */ #include @@ -56,16 +56,19 @@ __FBSDID("$FreeBSD$"); * settc * setty */ -#include "el.h" #include +#include + +#include "el.h" +#include "parse.h" private const struct { const Char *name; int (*func)(EditLine *, int, const Char **); } cmds[] = { - { STR("bind"), map_bind }, + { STR("bind"), map_bind }, { STR("echotc"), terminal_echotc }, - { STR("edit"), el_editmode }, + { STR("edit"), el_editmode }, { STR("history"), hist_command }, { STR("telltc"), terminal_telltc }, { STR("settc"), terminal_settc }, @@ -141,7 +144,7 @@ protected int parse__escape(const Char **ptr) { const Char *p; - Int c; + wint_t c; p = *ptr; @@ -253,7 +256,7 @@ parse__string(Char *out, const Char *in) case '^': if ((n = parse__escape(&in)) == -1) return NULL; - *out++ = n; + *out++ = (Char)n; break; case 'M': -- cgit v1.1