Module Name: src
Committed By: christos
Date: Wed Feb 17 19:47:49 UTC 2016
Modified Files:
src/lib/libedit: Makefile chared.c chartype.c chartype.h common.c el.c
el.h filecomplete.c hist.h histedit.h history.c keymacro.c makelist
map.c parse.c prompt.h read.c read.h readline.c refresh.c sys.h
terminal.c tokenizer.c tty.c vi.c
src/lib/libedit/TEST: tc1.c wtc1.c
src/lib/libedit/readline: Makefile readline.h
Log Message:
whitespace and header sorting changes (Ingo Schwarze). No functional changes.
To generate a diff of this commit:
cvs rdiff -u -r1.53 -r1.54 src/lib/libedit/Makefile src/lib/libedit/vi.c
cvs rdiff -u -r1.46 -r1.47 src/lib/libedit/chared.c
cvs rdiff -u -r1.18 -r1.19 src/lib/libedit/chartype.c
cvs rdiff -u -r1.20 -r1.21 src/lib/libedit/chartype.h
cvs rdiff -u -r1.37 -r1.38 src/lib/libedit/common.c
cvs rdiff -u -r1.81 -r1.82 src/lib/libedit/el.c src/lib/libedit/read.c
cvs rdiff -u -r1.32 -r1.33 src/lib/libedit/el.h
cvs rdiff -u -r1.39 -r1.40 src/lib/libedit/filecomplete.c
cvs rdiff -u -r1.17 -r1.18 src/lib/libedit/hist.h
cvs rdiff -u -r1.54 -r1.55 src/lib/libedit/histedit.h
cvs rdiff -u -r1.51 -r1.52 src/lib/libedit/history.c
cvs rdiff -u -r1.12 -r1.13 src/lib/libedit/keymacro.c \
src/lib/libedit/prompt.h
cvs rdiff -u -r1.23 -r1.24 src/lib/libedit/makelist \
src/lib/libedit/tokenizer.c
cvs rdiff -u -r1.42 -r1.43 src/lib/libedit/map.c
cvs rdiff -u -r1.34 -r1.35 src/lib/libedit/parse.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libedit/read.h
cvs rdiff -u -r1.124 -r1.125 src/lib/libedit/readline.c
cvs rdiff -u -r1.43 -r1.44 src/lib/libedit/refresh.c
cvs rdiff -u -r1.22 -r1.23 src/lib/libedit/sys.h
cvs rdiff -u -r1.21 -r1.22 src/lib/libedit/terminal.c
cvs rdiff -u -r1.56 -r1.57 src/lib/libedit/tty.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libedit/TEST/tc1.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libedit/TEST/wtc1.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libedit/readline/Makefile
cvs rdiff -u -r1.38 -r1.39 src/lib/libedit/readline/readline.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/lib/libedit/Makefile
diff -u src/lib/libedit/Makefile:1.53 src/lib/libedit/Makefile:1.54
--- src/lib/libedit/Makefile:1.53 Thu Jan 29 15:30:02 2015
+++ src/lib/libedit/Makefile Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.53 2015/01/29 20:30:02 joerg Exp $
+# $NetBSD: Makefile,v 1.54 2016/02/17 19:47:49 christos Exp $
# @(#)Makefile 8.1 (Berkeley) 6/4/93
USE_SHLIBDIR= yes
@@ -52,12 +52,12 @@ CLEANFILES+=editline.c
CLEANFILES+=common.h.tmp editline.c.tmp emacs.h.tmp fcns.c.tmp fcns.h.tmp
CLEANFILES+=help.c.tmp help.h.tmp vi.h.tmp tc1.o tc1
CLEANFILES+=tokenizern.c.tmp tokenizern.c tokenizerw.c.tmp tokenizerw.c
-CPPFLAGS+=-I. -I${LIBEDITDIR}
+CPPFLAGS+=-I. -I${LIBEDITDIR}
CPPFLAGS+=-I. -I${.CURDIR}
CPPFLAGS+=#-DDEBUG_TTY -DDEBUG_KEY -DDEBUG_READ -DDEBUG -DDEBUG_REFRESH
CPPFLAGS+=#-DDEBUG_PASTE -DDEBUG_EDIT
-AHDR=vi.h emacs.h common.h
+AHDR=vi.h emacs.h common.h
ASRC=${LIBEDITDIR}/vi.c ${LIBEDITDIR}/emacs.c ${LIBEDITDIR}/common.c
DPSRCS+= ${AHDR} fcns.h help.h fcns.c help.c
@@ -120,7 +120,7 @@ historyn.c: makelist Makefile
tc1.o: ${LIBEDITDIR}/TEST/tc1.c
-tc1: libedit.a tc1.o
+tc1: libedit.a tc1.o
${_MKTARGET_LINK}
${CC} ${LDFLAGS} ${.ALLSRC} -o ${.TARGET} libedit.a ${LDADD} -ltermlib
Index: src/lib/libedit/vi.c
diff -u src/lib/libedit/vi.c:1.53 src/lib/libedit/vi.c:1.54
--- src/lib/libedit/vi.c:1.53 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/vi.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: vi.c,v 1.53 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: vi.c,v 1.54 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)vi.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: vi.c,v 1.53 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: vi.c,v 1.54 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -585,7 +585,7 @@ vi_zero(EditLine *el, wint_t c)
/* vi_delete_prev_char():
- * Vi move to previous character (backspace)
+ * Vi move to previous character (backspace)
* [^H] in insert mode only
*/
protected el_action_t
@@ -977,7 +977,7 @@ vi_to_history_line(EditLine *el, wint_t
el->el_history.eventno = 1;
if (hist_get(el) == CC_ERROR)
return CC_ERROR;
- el->el_history.eventno = 1 + el->el_history.ev.num
+ el->el_history.eventno = 1 + el->el_history.ev.num
- el->el_state.argument;
if (el->el_history.eventno < 0) {
el->el_history.eventno = sv_event_no;
Index: src/lib/libedit/chared.c
diff -u src/lib/libedit/chared.c:1.46 src/lib/libedit/chared.c:1.47
--- src/lib/libedit/chared.c:1.46 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/chared.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: chared.c,v 1.46 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: chared.c,v 1.47 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)chared.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: chared.c,v 1.46 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: chared.c,v 1.47 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -526,7 +526,7 @@ ch_enlargebufs(EditLine *el, size_t addl
/* zero the newly added memory, leave old data in */
(void) memset(&newbuffer[sz], 0, (newsz - sz) * sizeof(*newbuffer));
-
+
oldbuf = el->el_line.buffer;
el->el_line.buffer = newbuffer;
@@ -575,7 +575,7 @@ ch_enlargebufs(EditLine *el, size_t addl
el->el_chared.c_redo.lim = newbuffer +
(el->el_chared.c_redo.lim - el->el_chared.c_redo.buf);
el->el_chared.c_redo.buf = newbuffer;
-
+
if (!hist_enlargebuf(el, sz, newsz))
return 0;
Index: src/lib/libedit/chartype.c
diff -u src/lib/libedit/chartype.c:1.18 src/lib/libedit/chartype.c:1.19
--- src/lib/libedit/chartype.c:1.18 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/chartype.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: chartype.c,v 1.18 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: chartype.c,v 1.19 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -38,7 +38,7 @@
*/
#include "config.h"
#if !defined(lint) && !defined(SCCSID)
-__RCSID("$NetBSD: chartype.c,v 1.18 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: chartype.c,v 1.19 2016/02/17 19:47:49 christos Exp $");
#endif /* not lint && not SCCSID */
#include <ctype.h>
@@ -76,7 +76,7 @@ ct_conv_wbuff_resize(ct_buffer_t *conv,
{
void *p;
- if (wsize <= conv->wsize)
+ if (wsize <= conv->wsize)
return 0;
conv->wsize = wsize;
Index: src/lib/libedit/chartype.h
diff -u src/lib/libedit/chartype.h:1.20 src/lib/libedit/chartype.h:1.21
--- src/lib/libedit/chartype.h:1.20 Sun Feb 14 12:06:24 2016
+++ src/lib/libedit/chartype.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: chartype.h,v 1.20 2016/02/14 17:06:24 christos Exp $ */
+/* $NetBSD: chartype.h,v 1.21 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -72,7 +72,7 @@
#define FUNW(type) type ## _w
#define TYPE(type) type ## W
#define FSTR "%ls"
-#define STR(x) L ## x
+#define STR(x) L ## x
#define UC(c) c
#define Isalpha(x) iswalpha(x)
#define Isalnum(x) iswalnum(x)
@@ -113,10 +113,10 @@ Width(wchar_t c)
#else /* NARROW */
-size_t ct_mbrtowc(char *, const char *, size_t, void *);
+size_t ct_mbrtowc(char *, const char *, size_t, void *);
#define ct_wctob(w) ((int)(w))
#define ct_wctomb error
-#define ct_wctomb_reset
+#define ct_wctomb_reset
#define ct_wcstombs(a, b, c) (strncpy(a, b, c), strlen(a))
#define ct_mbstowcs(a, b, c) (strncpy(a, b, c), strlen(a))
@@ -125,7 +125,7 @@ size_t ct_mbrtowc(char *, const char *,
#define FUNW(type) type
#define TYPE(type) type
#define FSTR "%s"
-#define STR(x) x
+#define STR(x) x
#define UC(c) (unsigned char)(c)
#define Isalpha(x) isalpha((unsigned char)x)
@@ -214,7 +214,7 @@ protected size_t ct_enc_width(Char);
#define VISUAL_WIDTH_MAX ((size_t)8)
/* The terminal is thought of in terms of X columns by Y lines. In the cases
- * where a wide character takes up more than one column, the adjacent
+ * where a wide character takes up more than one column, the adjacent
* occupied column entries will contain this faux character. */
#define MB_FILL_CHAR ((Char)-1)
Index: src/lib/libedit/common.c
diff -u src/lib/libedit/common.c:1.37 src/lib/libedit/common.c:1.38
--- src/lib/libedit/common.c:1.37 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/common.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: common.c,v 1.37 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: common.c,v 1.38 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)common.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: common.c,v 1.37 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: common.c,v 1.38 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -453,7 +453,7 @@ ed_unassigned(EditLine *el __attribute__
*/
protected el_action_t
/*ARGSUSED*/
-ed_tty_sigint(EditLine *el __attribute__((__unused__)),
+ed_tty_sigint(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -467,7 +467,7 @@ ed_tty_sigint(EditLine *el __attribute__
*/
protected el_action_t
/*ARGSUSED*/
-ed_tty_dsusp(EditLine *el __attribute__((__unused__)),
+ed_tty_dsusp(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -481,7 +481,7 @@ ed_tty_dsusp(EditLine *el __attribute__(
*/
protected el_action_t
/*ARGSUSED*/
-ed_tty_flush_output(EditLine *el __attribute__((__unused__)),
+ed_tty_flush_output(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -495,7 +495,7 @@ ed_tty_flush_output(EditLine *el __attri
*/
protected el_action_t
/*ARGSUSED*/
-ed_tty_sigquit(EditLine *el __attribute__((__unused__)),
+ed_tty_sigquit(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -509,7 +509,7 @@ ed_tty_sigquit(EditLine *el __attribute_
*/
protected el_action_t
/*ARGSUSED*/
-ed_tty_sigtstp(EditLine *el __attribute__((__unused__)),
+ed_tty_sigtstp(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -523,7 +523,7 @@ ed_tty_sigtstp(EditLine *el __attribute_
*/
protected el_action_t
/*ARGSUSED*/
-ed_tty_stop_output(EditLine *el __attribute__((__unused__)),
+ed_tty_stop_output(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -537,7 +537,7 @@ ed_tty_stop_output(EditLine *el __attrib
*/
protected el_action_t
/*ARGSUSED*/
-ed_tty_start_output(EditLine *el __attribute__((__unused__)),
+ed_tty_start_output(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -602,7 +602,7 @@ ed_clear_screen(EditLine *el, wint_t c _
*/
protected el_action_t
/*ARGSUSED*/
-ed_redisplay(EditLine *el __attribute__((__unused__)),
+ed_redisplay(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -630,7 +630,7 @@ ed_start_over(EditLine *el, wint_t c __a
*/
protected el_action_t
/*ARGSUSED*/
-ed_sequence_lead_in(EditLine *el __attribute__((__unused__)),
+ed_sequence_lead_in(EditLine *el __attribute__((__unused__)),
wint_t c __attribute__((__unused__)))
{
@@ -664,7 +664,6 @@ ed_prev_history(EditLine *el, wint_t c _
if (hist_get(el) == CC_ERROR) {
if (el->el_map.type == MAP_VI) {
el->el_history.eventno = sv_event;
-
}
beep = 1;
/* el->el_history.eventno was fixed by first call */
Index: src/lib/libedit/el.c
diff -u src/lib/libedit/el.c:1.81 src/lib/libedit/el.c:1.82
--- src/lib/libedit/el.c:1.81 Tue Feb 16 14:08:41 2016
+++ src/lib/libedit/el.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: el.c,v 1.81 2016/02/16 19:08:41 christos Exp $ */
+/* $NetBSD: el.c,v 1.82 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)el.c 8.2 (Berkeley) 1/3/94";
#else
-__RCSID("$NetBSD: el.c,v 1.81 2016/02/16 19:08:41 christos Exp $");
+__RCSID("$NetBSD: el.c,v 1.82 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -46,10 +46,10 @@ __RCSID("$NetBSD: el.c,v 1.81 2016/02/16
*/
#include <sys/types.h>
#include <sys/param.h>
-#include <string.h>
-#include <stdlib.h>
-#include <stdarg.h>
#include <ctype.h>
+#include <stdarg.h>
+#include <stdlib.h>
+#include <string.h>
#ifdef WIDECHAR
#include <locale.h>
#include <langinfo.h>
@@ -437,7 +437,7 @@ FUN(el,get)(EditLine *el, int op, ...)
char *argv[20];
int i;
- for (i = 1; i < (int)__arraycount(argv); i++)
+ for (i = 1; i < (int)__arraycount(argv); i++)
if ((argv[i] = va_arg(ap, char *)) == NULL)
break;
Index: src/lib/libedit/read.c
diff -u src/lib/libedit/read.c:1.81 src/lib/libedit/read.c:1.82
--- src/lib/libedit/read.c:1.81 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/read.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: read.c,v 1.81 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: read.c,v 1.82 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)read.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: read.c,v 1.81 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: read.c,v 1.82 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -48,10 +48,10 @@ __RCSID("$NetBSD: read.c,v 1.81 2016/02/
#include <ctype.h>
#include <errno.h>
#include <fcntl.h>
-#include <unistd.h>
+#include <limits.h>
#include <stdlib.h>
#include <string.h>
-#include <limits.h>
+#include <unistd.h>
#include "el.h"
Index: src/lib/libedit/el.h
diff -u src/lib/libedit/el.h:1.32 src/lib/libedit/el.h:1.33
--- src/lib/libedit/el.h:1.32 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/el.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: el.h,v 1.32 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: el.h,v 1.33 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -67,7 +67,7 @@ typedef struct coord_t { /* Position on
} coord_t;
typedef struct el_line_t {
- Char *buffer; /* Input line */
+ Char *buffer; /* Input line */
Char *cursor; /* Cursor position */
Char *lastchar; /* Last character */
const Char *limit; /* Max position */
@@ -82,7 +82,7 @@ typedef struct el_state_t {
int argument; /* Numeric argument */
int metanext; /* Is the next char a meta char */
el_action_t lastcmd; /* Previous command */
- el_action_t thiscmd; /* this command */
+ el_action_t thiscmd; /* this command */
Char thisch; /* char that generated it */
} el_state_t;
Index: src/lib/libedit/filecomplete.c
diff -u src/lib/libedit/filecomplete.c:1.39 src/lib/libedit/filecomplete.c:1.40
--- src/lib/libedit/filecomplete.c:1.39 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/filecomplete.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: filecomplete.c,v 1.39 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: filecomplete.c,v 1.40 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1997 The NetBSD Foundation, Inc.
@@ -31,20 +31,20 @@
#include "config.h"
#if !defined(lint) && !defined(SCCSID)
-__RCSID("$NetBSD: filecomplete.c,v 1.39 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: filecomplete.c,v 1.40 2016/02/17 19:47:49 christos Exp $");
#endif /* not lint && not SCCSID */
#include <sys/types.h>
#include <sys/stat.h>
-#include <stdio.h>
#include <dirent.h>
-#include <string.h>
+#include <errno.h>
+#include <fcntl.h>
+#include <limits.h>
#include <pwd.h>
+#include <stdio.h>
#include <stdlib.h>
+#include <string.h>
#include <unistd.h>
-#include <limits.h>
-#include <errno.h>
-#include <fcntl.h>
#include "el.h"
#include "filecomplete.h"
@@ -93,9 +93,9 @@ fn_tilde_expand(const char *txt)
}
if (temp[0] == 0) {
#ifdef HAVE_GETPW_R_POSIX
- if (getpwuid_r(getuid(), &pwres, pwbuf, sizeof(pwbuf),
+ if (getpwuid_r(getuid(), &pwres, pwbuf, sizeof(pwbuf),
&pass) != 0)
- pass = NULL;
+ pass = NULL;
#elif HAVE_GETPW_R_DRAFT
pass = getpwuid_r(getuid(), &pwres, pwbuf, sizeof(pwbuf));
#else
@@ -461,7 +461,7 @@ fn_complete(EditLine *el,
cur_off - (int)len, cur_off);
} else
matches = 0;
- if (!attempted_completion_function ||
+ if (!attempted_completion_function ||
(over != NULL && !*over && !matches))
matches = completion_matches(
ct_encode_string(temp, &el->el_scratch), complet_func);
@@ -511,7 +511,7 @@ fn_complete(EditLine *el,
}
/* matches[1] through matches[i-1] are available */
matches_num = (size_t)(i - 1);
-
+
/* newline to get on next line from command line */
(void)fprintf(el->el_outfile, "\n");
Index: src/lib/libedit/hist.h
diff -u src/lib/libedit/hist.h:1.17 src/lib/libedit/hist.h:1.18
--- src/lib/libedit/hist.h:1.17 Tue Feb 16 10:53:48 2016
+++ src/lib/libedit/hist.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: hist.h,v 1.17 2016/02/16 15:53:48 christos Exp $ */
+/* $NetBSD: hist.h,v 1.18 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -80,7 +80,7 @@ protected int hist_set(EditLine *, hist
protected int hist_command(EditLine *, int, const Char **);
protected int hist_enlargebuf(EditLine *, size_t, size_t);
#ifdef WIDECHAR
-protected wchar_t *hist_convert(EditLine *, int, void *);
+protected wchar_t *hist_convert(EditLine *, int, void *);
#endif
#endif /* _h_el_hist */
Index: src/lib/libedit/histedit.h
diff -u src/lib/libedit/histedit.h:1.54 src/lib/libedit/histedit.h:1.55
--- src/lib/libedit/histedit.h:1.54 Tue Feb 16 14:29:51 2016
+++ src/lib/libedit/histedit.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: histedit.h,v 1.54 2016/02/16 19:29:51 christos Exp $ */
+/* $NetBSD: histedit.h,v 1.55 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -128,7 +128,7 @@ unsigned char _el_fn_complete(EditLine *
* For operations that support set or set/get, the argument types listed are for
* the "set" operation. For "get", each listed type must be a pointer.
* E.g. EL_EDITMODE takes an int when set, but an int* when get.
- *
+ *
* Operations that only support "get" have the correct argument types listed.
*/
#define EL_PROMPT 0 /* , prompt_func); set/get */
@@ -141,7 +141,7 @@ unsigned char _el_fn_complete(EditLine *
#define EL_ECHOTC 7 /* , const Char *, ..., NULL); set */
#define EL_SETTY 8 /* , const Char *, ..., NULL); set */
#define EL_ADDFN 9 /* , const Char *, const Char, set */
- /* el_func_t); */
+ /* el_func_t); */
#define EL_HIST 10 /* , hist_fun_t, const void *); set */
#define EL_EDITMODE 11 /* , int); set/get */
#define EL_RPROMPT 12 /* , prompt_func); set/get */
Index: src/lib/libedit/history.c
diff -u src/lib/libedit/history.c:1.51 src/lib/libedit/history.c:1.52
--- src/lib/libedit/history.c:1.51 Mon Feb 15 16:35:52 2016
+++ src/lib/libedit/history.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: history.c,v 1.51 2016/02/15 21:35:52 christos Exp $ */
+/* $NetBSD: history.c,v 1.52 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,18 +37,18 @@
#if 0
static char sccsid[] = "@(#)history.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: history.c,v 1.51 2016/02/15 21:35:52 christos Exp $");
+__RCSID("$NetBSD: history.c,v 1.52 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
/*
* hist.c: TYPE(History) access functions
*/
-#include <string.h>
-#include <stdlib.h>
+#include <sys/stat.h>
#include <stdarg.h>
+#include <stdlib.h>
+#include <string.h>
#include <vis.h>
-#include <sys/stat.h>
static const char hist_cookie[] = "_HiStOrY_V2_\n";
@@ -437,7 +437,7 @@ history_def_del(void *p, TYPE(HistEvent)
*/
/* ARGSUSED */
private void
-history_def_delete(history_t *h,
+history_def_delete(history_t *h,
TYPE(HistEvent) *ev __attribute__((__unused__)), hentry_t *hp)
{
HistEventPrivate *evp = (void *)&hp->ev;
Index: src/lib/libedit/keymacro.c
diff -u src/lib/libedit/keymacro.c:1.12 src/lib/libedit/keymacro.c:1.13
--- src/lib/libedit/keymacro.c:1.12 Tue Feb 16 10:53:48 2016
+++ src/lib/libedit/keymacro.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: keymacro.c,v 1.12 2016/02/16 15:53:48 christos Exp $ */
+/* $NetBSD: keymacro.c,v 1.13 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)key.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: keymacro.c,v 1.12 2016/02/16 15:53:48 christos Exp $");
+__RCSID("$NetBSD: keymacro.c,v 1.13 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -63,8 +63,8 @@ __RCSID("$NetBSD: keymacro.c,v 1.12 2016
* 1) It is not possible to have one key that is a
* substr of another.
*/
-#include <string.h>
#include <stdlib.h>
+#include <string.h>
#include "el.h"
@@ -73,10 +73,10 @@ __RCSID("$NetBSD: keymacro.c,v 1.12 2016
* linked list of these node elements
*/
struct keymacro_node_t {
- Char ch; /* single character of key */
+ Char ch; /* single character of key */
int type; /* node type */
keymacro_value_t val; /* command code or pointer to str, */
- /* if this is a leaf */
+ /* if this is a leaf */
struct keymacro_node_t *next; /* ptr to next char of this key */
struct keymacro_node_t *sibling;/* ptr to another key with same prefix*/
};
@@ -275,7 +275,7 @@ keymacro_print(EditLine *el, const Char
/* node_trav():
* recursively traverses node in tree until match or mismatch is
- * found. May read in more characters.
+ * found. May read in more characters.
*/
private int
node_trav(EditLine *el, keymacro_node_t *ptr, Char *ch, keymacro_value_t *val)
@@ -312,7 +312,7 @@ node_trav(EditLine *el, keymacro_node_t
/* node__try():
- * Find a node that matches *str or allocate a new one
+ * Find a node that matches *str or allocate a new one
*/
private int
node__try(EditLine *el, keymacro_node_t *ptr, const Char *str,
@@ -594,7 +594,7 @@ keymacro_kprint(EditLine *el, const Char
case XK_STR:
case XK_EXE:
(void) keymacro__decode_str(val->str, unparsbuf,
- sizeof(unparsbuf),
+ sizeof(unparsbuf),
ntype == XK_STR ? "\"\"" : "[]");
(void) fprintf(el->el_outfile, fmt,
ct_encode_string(key, &el->el_scratch), unparsbuf);
Index: src/lib/libedit/prompt.h
diff -u src/lib/libedit/prompt.h:1.12 src/lib/libedit/prompt.h:1.13
--- src/lib/libedit/prompt.h:1.12 Tue Feb 16 10:53:48 2016
+++ src/lib/libedit/prompt.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: prompt.h,v 1.12 2016/02/16 15:53:48 christos Exp $ */
+/* $NetBSD: prompt.h,v 1.13 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -46,7 +46,7 @@ typedef struct el_prompt_t {
el_pfunc_t p_func; /* Function to return the prompt */
coord_t p_pos; /* position in the line after prompt */
Char p_ignore; /* character to start/end literal */
- int p_wide;
+ int p_wide;
} el_prompt_t;
protected void prompt_print(EditLine *, int);
Index: src/lib/libedit/makelist
diff -u src/lib/libedit/makelist:1.23 src/lib/libedit/makelist:1.24
--- src/lib/libedit/makelist:1.23 Tue Feb 16 14:08:41 2016
+++ src/lib/libedit/makelist Wed Feb 17 14:47:49 2016
@@ -1,5 +1,5 @@
#!/bin/sh -
-# $NetBSD: makelist,v 1.23 2016/02/16 19:08:41 christos Exp $
+# $NetBSD: makelist,v 1.24 2016/02/17 19:47:49 christos Exp $
#
# Copyright (c) 1992, 1993
# The Regents of the University of California. All rights reserved.
@@ -61,7 +61,7 @@ case $FLAG in
#include "${FILES}"
_EOF
;;
-
+
-h)
set - `echo $FILES | sed -e 's/\\./_/g'`
hdr="_h_`basename $1`"
Index: src/lib/libedit/tokenizer.c
diff -u src/lib/libedit/tokenizer.c:1.23 src/lib/libedit/tokenizer.c:1.24
--- src/lib/libedit/tokenizer.c:1.23 Mon Feb 15 10:37:20 2016
+++ src/lib/libedit/tokenizer.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: tokenizer.c,v 1.23 2016/02/15 15:37:20 christos Exp $ */
+/* $NetBSD: tokenizer.c,v 1.24 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)tokenizer.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: tokenizer.c,v 1.23 2016/02/15 15:37:20 christos Exp $");
+__RCSID("$NetBSD: tokenizer.c,v 1.24 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -45,8 +45,9 @@ __RCSID("$NetBSD: tokenizer.c,v 1.23 201
/*
* tokenize.c: Bourne shell like tokenizer
*/
-#include <string.h>
#include <stdlib.h>
+#include <string.h>
+
#include "histedit.h"
#include "chartype.h"
Index: src/lib/libedit/map.c
diff -u src/lib/libedit/map.c:1.42 src/lib/libedit/map.c:1.43
--- src/lib/libedit/map.c:1.42 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/map.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: map.c,v 1.42 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: map.c,v 1.43 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)map.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: map.c,v 1.42 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: map.c,v 1.43 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -1159,7 +1159,7 @@ map_print_some_keys(EditLine *el, el_act
lastbuf[1] = 0;
if (map[first] == ED_UNASSIGNED) {
if (first == last) {
- (void) keymacro__decode_str(firstbuf, unparsbuf,
+ (void) keymacro__decode_str(firstbuf, unparsbuf,
sizeof(unparsbuf), STRQQ);
(void) fprintf(el->el_outfile,
"%-15s-> is undefined\n", unparsbuf);
@@ -1170,14 +1170,14 @@ map_print_some_keys(EditLine *el, el_act
for (bp = el->el_map.help; bp < ep; bp++) {
if (bp->func == map[first]) {
if (first == last) {
- (void) keymacro__decode_str(firstbuf, unparsbuf,
+ (void) keymacro__decode_str(firstbuf, unparsbuf,
sizeof(unparsbuf), STRQQ);
(void) fprintf(el->el_outfile, "%-15s-> " FSTR "\n",
unparsbuf, bp->name);
} else {
- (void) keymacro__decode_str(firstbuf, unparsbuf,
+ (void) keymacro__decode_str(firstbuf, unparsbuf,
sizeof(unparsbuf), STRQQ);
- (void) keymacro__decode_str(lastbuf, extrabuf,
+ (void) keymacro__decode_str(lastbuf, extrabuf,
sizeof(extrabuf), STRQQ);
(void) fprintf(el->el_outfile,
"%-4s to %-7s-> " FSTR "\n",
@@ -1188,14 +1188,14 @@ map_print_some_keys(EditLine *el, el_act
}
#ifdef MAP_DEBUG
if (map == el->el_map.key) {
- (void) keymacro__decode_str(firstbuf, unparsbuf,
+ (void) keymacro__decode_str(firstbuf, unparsbuf,
sizeof(unparsbuf), STRQQ);
(void) fprintf(el->el_outfile,
"BUG!!! %s isn't bound to anything.\n", unparsbuf);
(void) fprintf(el->el_outfile, "el->el_map.key[%d] == %d\n",
first, el->el_map.key[first]);
} else {
- (void) keymacro__decode_str(firstbuf, unparsbuf,
+ (void) keymacro__decode_str(firstbuf, unparsbuf,
sizeof(unparsbuf), STRQQ);
(void) fprintf(el->el_outfile,
"BUG!!! %s isn't bound to anything.\n", unparsbuf);
Index: src/lib/libedit/parse.c
diff -u src/lib/libedit/parse.c:1.34 src/lib/libedit/parse.c:1.35
--- src/lib/libedit/parse.c:1.34 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/parse.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: parse.c,v 1.34 2016/02/16 22:53:14 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.34 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: parse.c,v 1.35 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -64,9 +64,9 @@ 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 },
Index: src/lib/libedit/read.h
diff -u src/lib/libedit/read.h:1.7 src/lib/libedit/read.h:1.8
--- src/lib/libedit/read.h:1.7 Wed Dec 30 17:37:40 2009
+++ src/lib/libedit/read.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: read.h,v 1.7 2009/12/30 22:37:40 christos Exp $ */
+/* $NetBSD: read.h,v 1.8 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -40,7 +40,7 @@ typedef int (*el_rfunc_t)(EditLine *, Ch
typedef struct el_read_t {
el_rfunc_t read_char; /* Function to read a character */
} el_read_t;
-
+
protected int read_init(EditLine *);
protected void read_prepare(EditLine *);
protected void read_finish(EditLine *);
Index: src/lib/libedit/readline.c
diff -u src/lib/libedit/readline.c:1.124 src/lib/libedit/readline.c:1.125
--- src/lib/libedit/readline.c:1.124 Tue Feb 16 14:08:41 2016
+++ src/lib/libedit/readline.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: readline.c,v 1.124 2016/02/16 19:08:41 christos Exp $ */
+/* $NetBSD: readline.c,v 1.125 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1997 The NetBSD Foundation, Inc.
@@ -31,23 +31,23 @@
#include "config.h"
#if !defined(lint) && !defined(SCCSID)
-__RCSID("$NetBSD: readline.c,v 1.124 2016/02/16 19:08:41 christos Exp $");
+__RCSID("$NetBSD: readline.c,v 1.125 2016/02/17 19:47:49 christos Exp $");
#endif /* not lint && not SCCSID */
#include <sys/types.h>
#include <sys/stat.h>
-#include <stdio.h>
-#include <stdint.h>
-#include <dirent.h>
-#include <string.h>
-#include <pwd.h>
#include <ctype.h>
-#include <stdlib.h>
-#include <unistd.h>
-#include <limits.h>
+#include <dirent.h>
#include <errno.h>
#include <fcntl.h>
+#include <limits.h>
+#include <pwd.h>
#include <setjmp.h>
+#include <stdint.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
#include <vis.h>
#include "readline/readline.h"
@@ -266,7 +266,7 @@ rl_set_prompt(const char *prompt)
if (!prompt)
prompt = "";
- if (rl_prompt != NULL && strcmp(rl_prompt, prompt) == 0)
+ if (rl_prompt != NULL && strcmp(rl_prompt, prompt) == 0)
return 0;
if (rl_prompt)
el_free(rl_prompt);
@@ -360,7 +360,7 @@ rl_initialize(void)
"ReadLine compatible suspend function",
_el_rl_tstp);
el_set(e, EL_BIND, "^Z", "rl_tstp", NULL);
-
+
/*
* Set some readline compatible key-bindings.
*/
@@ -2007,7 +2007,7 @@ rl_callback_read_char(void)
}
}
-void
+void
rl_callback_handler_install(const char *prompt, rl_vcpfunc_t *linefunc)
{
if (e == NULL) {
@@ -2016,9 +2016,9 @@ rl_callback_handler_install(const char *
(void)rl_set_prompt(prompt);
rl_linefunc = linefunc;
el_set(e, EL_UNBUFFERED, 1);
-}
+}
-void
+void
rl_callback_handler_remove(void)
{
el_set(e, EL_UNBUFFERED, 0);
@@ -2218,7 +2218,7 @@ rl_completion_matches(const char *str, r
list[0][min] = '\0';
}
return list;
-
+
out:
el_free(list);
return NULL;
Index: src/lib/libedit/refresh.c
diff -u src/lib/libedit/refresh.c:1.43 src/lib/libedit/refresh.c:1.44
--- src/lib/libedit/refresh.c:1.43 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/refresh.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: refresh.c,v 1.43 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: refresh.c,v 1.44 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)refresh.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: refresh.c,v 1.43 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: refresh.c,v 1.44 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -45,8 +45,8 @@ __RCSID("$NetBSD: refresh.c,v 1.43 2016/
* refresh.c: Lower level screen refreshing functions
*/
#include <stdio.h>
-#include <unistd.h>
#include <string.h>
+#include <unistd.h>
#include "el.h"
@@ -63,7 +63,7 @@ private void re__copy_and_pad(Char *, co
#ifdef DEBUG_REFRESH
private void re_printstr(EditLine *, const char *, char *, char *);
#define __F el->el_errfile
-#define ELRE_ASSERT(a, b, c) do \
+#define ELRE_ASSERT(a, b, c) do \
if (/*CONSTCOND*/ a) { \
(void) fprintf b; \
c; \
@@ -109,7 +109,7 @@ re_nextline(EditLine *el)
for(i = 1; i < lins; i++)
el->el_vdisplay[i - 1] = el->el_vdisplay[i];
- firstline[0] = '\0'; /* empty the string */
+ firstline[0] = '\0'; /* empty the string */
el->el_vdisplay[i - 1] = firstline;
} else
el->el_refresh.r_cursor.v++;
@@ -191,7 +191,7 @@ re_putc(EditLine *el, wint_t c, int shif
/* re_refresh():
* draws the new virtual screen image from the current input
- * line, then goes line-by-line changing the real image to the new
+ * line, then goes line-by-line changing the real image to the new
* virtual image. The routine to re-draw a line can be replaced
* easily in hopes of a smarter one being placed there.
*/
@@ -450,7 +450,7 @@ re__strncopy(Char *a, Char *b, size_t n)
* in order to make sure that we have cleared the previous contents of
* the line. fx and sx is the number of characters inserted or deleted
* in the first or second diff, diff is the difference between the
- * number of characters between the new and old line.
+ * number of characters between the new and old line.
*/
private void
re_clear_eol(EditLine *el, int fx, int sx, int diff)
@@ -1076,7 +1076,7 @@ re_fastputc(EditLine *el, wint_t c)
if (el->el_cursor.v + 1 >= el->el_terminal.t_size.v) {
int i, lins = el->el_terminal.t_size.v;
Char *firstline = el->el_display[0];
-
+
for(i = 1; i < lins; i++)
el->el_display[i - 1] = el->el_display[i];
Index: src/lib/libedit/sys.h
diff -u src/lib/libedit/sys.h:1.22 src/lib/libedit/sys.h:1.23
--- src/lib/libedit/sys.h:1.22 Tue Feb 16 14:29:51 2016
+++ src/lib/libedit/sys.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: sys.h,v 1.22 2016/02/16 19:29:51 christos Exp $ */
+/* $NetBSD: sys.h,v 1.23 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -57,7 +57,7 @@
# define __END_DECLS
# endif
#endif
-
+
#ifndef public
# define public /* Externally visible functions/variables */
#endif
@@ -112,7 +112,7 @@ typedef unsigned int u_int32_t;
#undef REGEXP /* Use UNIX V8 regular expression functions */
#ifndef WIDECHAR
-#define setlocale(c, l) /*LINTED*/NULL
+#define setlocale(c, l) /*LINTED*/NULL
#define nl_langinfo(i) ""
#endif
Index: src/lib/libedit/terminal.c
diff -u src/lib/libedit/terminal.c:1.21 src/lib/libedit/terminal.c:1.22
--- src/lib/libedit/terminal.c:1.21 Tue Feb 16 10:53:48 2016
+++ src/lib/libedit/terminal.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: terminal.c,v 1.21 2016/02/16 15:53:48 christos Exp $ */
+/* $NetBSD: terminal.c,v 1.22 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)term.c 8.2 (Berkeley) 4/30/95";
#else
-__RCSID("$NetBSD: terminal.c,v 1.21 2016/02/16 15:53:48 christos Exp $");
+__RCSID("$NetBSD: terminal.c,v 1.22 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -46,12 +46,14 @@ __RCSID("$NetBSD: terminal.c,v 1.21 2016
* We have to declare a static variable here, since the
* termcap putchar routine does not take an argument!
*/
-#include <stdio.h>
+#include <sys/types.h>
+#include <sys/ioctl.h>
+#include <limits.h>
#include <signal.h>
-#include <string.h>
+#include <stdio.h>
#include <stdlib.h>
+#include <string.h>
#include <unistd.h>
-#include <limits.h>
#ifdef HAVE_TERMCAP_H
#include <termcap.h>
#endif
@@ -65,9 +67,6 @@ __RCSID("$NetBSD: terminal.c,v 1.21 2016
#if defined(HAVE_TERM_H) && !defined(__sun) && !defined(HAVE_TERMCAP_H)
#include <term.h>
#endif
-
-#include <sys/types.h>
-#include <sys/ioctl.h>
#ifdef _REENTRANT
#include <pthread.h>
@@ -494,7 +493,7 @@ terminal_free_display(EditLine *el)
/* terminal_move_to_line():
* move to line <where> (first line == 0)
- * as efficiently as possible
+ * as efficiently as possible
*/
protected void
terminal_move_to_line(EditLine *el, int where)
@@ -609,7 +608,7 @@ mc_again:
i < (where & ~0x7);
i += 8)
terminal__putc(el,
- '\t');
+ '\t');
/* then tab over */
el->el_cursor.h = where & ~0x7;
}
@@ -1298,7 +1297,7 @@ terminal_writec(EditLine *el, wint_t c)
*/
protected int
/*ARGSUSED*/
-terminal_telltc(EditLine *el, int argc __attribute__((__unused__)),
+terminal_telltc(EditLine *el, int argc __attribute__((__unused__)),
const Char **argv __attribute__((__unused__)))
{
const struct termcapstr *t;
Index: src/lib/libedit/tty.c
diff -u src/lib/libedit/tty.c:1.56 src/lib/libedit/tty.c:1.57
--- src/lib/libedit/tty.c:1.56 Tue Feb 16 17:53:14 2016
+++ src/lib/libedit/tty.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: tty.c,v 1.56 2016/02/16 22:53:14 christos Exp $ */
+/* $NetBSD: tty.c,v 1.57 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)tty.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: tty.c,v 1.56 2016/02/16 22:53:14 christos Exp $");
+__RCSID("$NetBSD: tty.c,v 1.57 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
@@ -46,10 +46,10 @@ __RCSID("$NetBSD: tty.c,v 1.56 2016/02/1
*/
#include <assert.h>
#include <errno.h>
-#include <unistd.h> /* for isatty */
-#include <strings.h> /* for ffs */
#include <stdlib.h> /* for abort */
#include <string.h>
+#include <strings.h> /* for ffs */
+#include <unistd.h> /* for isatty */
#include "el.h"
#include "parse.h"
@@ -978,7 +978,7 @@ tty_update_char(EditLine *el, int mode,
/* tty_rawmode():
- * Set terminal into 1 character at a time mode.
+ * Set terminal into 1 character at a time mode.
*/
protected int
tty_rawmode(EditLine *el)
Index: src/lib/libedit/TEST/tc1.c
diff -u src/lib/libedit/TEST/tc1.c:1.6 src/lib/libedit/TEST/tc1.c:1.7
--- src/lib/libedit/TEST/tc1.c:1.6 Wed Jun 18 16:12:15 2014
+++ src/lib/libedit/TEST/tc1.c Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: tc1.c,v 1.6 2014/06/18 20:12:15 christos Exp $ */
+/* $NetBSD: tc1.c,v 1.7 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -42,22 +42,22 @@ __COPYRIGHT("@(#) Copyright (c) 1992, 19
#if 0
static char sccsid[] = "@(#)test.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: tc1.c,v 1.6 2014/06/18 20:12:15 christos Exp $");
+__RCSID("$NetBSD: tc1.c,v 1.7 2016/02/17 19:47:49 christos Exp $");
#endif
#endif /* not lint && not SCCSID */
/*
* test.c: A little test program
*/
-#include <stdio.h>
-#include <string.h>
-#include <signal.h>
#include <sys/wait.h>
#include <ctype.h>
-#include <stdlib.h>
-#include <unistd.h>
#include <dirent.h>
#include <locale.h>
+#include <signal.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
#include "histedit.h"
@@ -157,7 +157,7 @@ main(int argc, char *argv[])
/* Add a user-defined function */
el_set(el, EL_ADDFN, "ed-complete", "Complete argument", complete);
- /* Bind tab to it */
+ /* Bind tab to it */
el_set(el, EL_BIND, "^I", "ed-complete", NULL);
/*
Index: src/lib/libedit/TEST/wtc1.c
diff -u src/lib/libedit/TEST/wtc1.c:1.7 src/lib/libedit/TEST/wtc1.c:1.8
--- src/lib/libedit/TEST/wtc1.c:1.7 Wed Jun 18 16:12:15 2014
+++ src/lib/libedit/TEST/wtc1.c Wed Feb 17 14:47:49 2016
@@ -1,14 +1,14 @@
-#include <stdio.h>
-#include <string.h>
-#include <signal.h>
#include <sys/wait.h>
-#include <err.h>
#include <ctype.h>
-#include <stdlib.h>
-#include <unistd.h>
#include <dirent.h>
+#include <err.h>
#include <limits.h>
#include <locale.h>
+#include <signal.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
#include "../histedit.h"
Index: src/lib/libedit/readline/Makefile
diff -u src/lib/libedit/readline/Makefile:1.7 src/lib/libedit/readline/Makefile:1.8
--- src/lib/libedit/readline/Makefile:1.7 Sun Aug 3 05:23:15 2003
+++ src/lib/libedit/readline/Makefile Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.7 2003/08/03 09:23:15 lukem Exp $
+# $NetBSD: Makefile,v 1.8 2016/02/17 19:47:49 christos Exp $
NOOBJ= # defined
Index: src/lib/libedit/readline/readline.h
diff -u src/lib/libedit/readline/readline.h:1.38 src/lib/libedit/readline/readline.h:1.39
--- src/lib/libedit/readline/readline.h:1.38 Mon Feb 15 16:58:38 2016
+++ src/lib/libedit/readline/readline.h Wed Feb 17 14:47:49 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: readline.h,v 1.38 2016/02/15 21:58:38 christos Exp $ */
+/* $NetBSD: readline.h,v 1.39 2016/02/17 19:47:49 christos Exp $ */
/*-
* Copyright (c) 1997 The NetBSD Foundation, Inc.
@@ -53,7 +53,7 @@ typedef void *histdata_t;
typedef struct _hist_entry {
const char *line;
- histdata_t data;
+ histdata_t data;
} HIST_ENTRY;
typedef struct _keymap_entry {
@@ -87,7 +87,7 @@ typedef KEYMAP_ENTRY *Keymap;
#define RUBOUT 0x7f
#define ABORT_CHAR CTRL('G')
-#define RL_READLINE_VERSION 0x0402
+#define RL_READLINE_VERSION 0x0402
#define RL_PROMPT_START_IGNORE '\1'
#define RL_PROMPT_END_IGNORE '\2'
@@ -96,7 +96,7 @@ typedef KEYMAP_ENTRY *Keymap;
extern "C" {
#endif
extern const char *rl_library_version;
-extern int rl_readline_version;
+extern int rl_readline_version;
extern char *rl_readline_name;
extern FILE *rl_instream;
extern FILE *rl_outstream;
@@ -197,10 +197,10 @@ int rl_add_defun(const char *, rl_comm
HISTORY_STATE *history_get_history_state(void);
void rl_get_screen_size(int *, int *);
void rl_set_screen_size(int, int);
-char *rl_filename_completion_function (const char *, int);
+char *rl_filename_completion_function (const char *, int);
int _rl_abort_internal(void);
int _rl_qsort_string_compare(char **, char **);
-char **rl_completion_matches(const char *, rl_compentry_func_t *);
+char **rl_completion_matches(const char *, rl_compentry_func_t *);
void rl_forced_update_display(void);
int rl_set_prompt(const char *);
int rl_on_new_line(void);