Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 Apr 2015 13:26:06 +0000 (UTC)
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org
Subject:   svn commit: r281368 - in vendor/nvi/dist: . catalog cl common docs docs/USD.doc docs/internals docs/interp docs/man docs/tutorial ex regex vi
Message-ID:  <201504101326.t3ADQ6X2098127@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Fri Apr 10 13:26:05 2015
New Revision: 281368
URL: https://svnweb.freebsd.org/changeset/base/281368

Log:
  Import nvi 2.1.3
  
  Approved by:	peter

Added:
  vendor/nvi/dist/docs/man/
  vendor/nvi/dist/docs/man/Makefile   (contents, props changed)
  vendor/nvi/dist/docs/man/vi.1   (contents, props changed)
Deleted:
  vendor/nvi/dist/catalog/spell.ok
  vendor/nvi/dist/docs/TODO
  vendor/nvi/dist/docs/USD.doc/
  vendor/nvi/dist/docs/changelog
  vendor/nvi/dist/docs/ev
  vendor/nvi/dist/docs/features
  vendor/nvi/dist/docs/help
  vendor/nvi/dist/docs/internals/
  vendor/nvi/dist/docs/interp/
  vendor/nvi/dist/docs/spell.ok
  vendor/nvi/dist/docs/tutorial/
Modified:
  vendor/nvi/dist/README
  vendor/nvi/dist/catalog/dump.c
  vendor/nvi/dist/cl/cl.h
  vendor/nvi/dist/cl/cl_funcs.c
  vendor/nvi/dist/cl/cl_main.c
  vendor/nvi/dist/cl/cl_read.c
  vendor/nvi/dist/cl/cl_screen.c
  vendor/nvi/dist/cl/cl_term.c
  vendor/nvi/dist/cl/extern.h
  vendor/nvi/dist/common/common.h
  vendor/nvi/dist/common/conv.c
  vendor/nvi/dist/common/cut.c
  vendor/nvi/dist/common/delete.c
  vendor/nvi/dist/common/encoding.c
  vendor/nvi/dist/common/exf.c
  vendor/nvi/dist/common/extern.h
  vendor/nvi/dist/common/gs.h
  vendor/nvi/dist/common/key.c
  vendor/nvi/dist/common/line.c
  vendor/nvi/dist/common/log.c
  vendor/nvi/dist/common/main.c
  vendor/nvi/dist/common/mark.c
  vendor/nvi/dist/common/msg.c
  vendor/nvi/dist/common/options.c
  vendor/nvi/dist/common/options.h
  vendor/nvi/dist/common/options_f.c
  vendor/nvi/dist/common/put.c
  vendor/nvi/dist/common/recover.c
  vendor/nvi/dist/common/screen.c
  vendor/nvi/dist/common/search.c
  vendor/nvi/dist/common/seq.c
  vendor/nvi/dist/common/util.c
  vendor/nvi/dist/ex/ex.c
  vendor/nvi/dist/ex/ex.h
  vendor/nvi/dist/ex/ex_abbrev.c
  vendor/nvi/dist/ex/ex_append.c
  vendor/nvi/dist/ex/ex_args.c
  vendor/nvi/dist/ex/ex_argv.c
  vendor/nvi/dist/ex/ex_at.c
  vendor/nvi/dist/ex/ex_bang.c
  vendor/nvi/dist/ex/ex_cd.c
  vendor/nvi/dist/ex/ex_cscope.c
  vendor/nvi/dist/ex/ex_delete.c
  vendor/nvi/dist/ex/ex_display.c
  vendor/nvi/dist/ex/ex_edit.c
  vendor/nvi/dist/ex/ex_equal.c
  vendor/nvi/dist/ex/ex_file.c
  vendor/nvi/dist/ex/ex_filter.c
  vendor/nvi/dist/ex/ex_global.c
  vendor/nvi/dist/ex/ex_init.c
  vendor/nvi/dist/ex/ex_join.c
  vendor/nvi/dist/ex/ex_map.c
  vendor/nvi/dist/ex/ex_mark.c
  vendor/nvi/dist/ex/ex_mkexrc.c
  vendor/nvi/dist/ex/ex_move.c
  vendor/nvi/dist/ex/ex_open.c
  vendor/nvi/dist/ex/ex_preserve.c
  vendor/nvi/dist/ex/ex_print.c
  vendor/nvi/dist/ex/ex_put.c
  vendor/nvi/dist/ex/ex_quit.c
  vendor/nvi/dist/ex/ex_read.c
  vendor/nvi/dist/ex/ex_screen.c
  vendor/nvi/dist/ex/ex_script.c
  vendor/nvi/dist/ex/ex_set.c
  vendor/nvi/dist/ex/ex_shell.c
  vendor/nvi/dist/ex/ex_shift.c
  vendor/nvi/dist/ex/ex_source.c
  vendor/nvi/dist/ex/ex_stop.c
  vendor/nvi/dist/ex/ex_subst.c
  vendor/nvi/dist/ex/ex_tag.c
  vendor/nvi/dist/ex/ex_txt.c
  vendor/nvi/dist/ex/ex_undo.c
  vendor/nvi/dist/ex/ex_usage.c
  vendor/nvi/dist/ex/ex_util.c
  vendor/nvi/dist/ex/ex_version.c
  vendor/nvi/dist/ex/ex_visual.c
  vendor/nvi/dist/ex/ex_write.c
  vendor/nvi/dist/ex/ex_yank.c
  vendor/nvi/dist/ex/ex_z.c
  vendor/nvi/dist/ex/extern.h
  vendor/nvi/dist/ex/version.h
  vendor/nvi/dist/regex/COPYRIGHT
  vendor/nvi/dist/regex/cclass.h
  vendor/nvi/dist/regex/cname.h
  vendor/nvi/dist/regex/engine.c
  vendor/nvi/dist/regex/re_format.7
  vendor/nvi/dist/regex/regcomp.c
  vendor/nvi/dist/regex/regerror.c
  vendor/nvi/dist/regex/regex.3
  vendor/nvi/dist/regex/regex.h
  vendor/nvi/dist/regex/regex2.h
  vendor/nvi/dist/regex/regexec.c
  vendor/nvi/dist/regex/regfree.c
  vendor/nvi/dist/regex/utils.h
  vendor/nvi/dist/vi/extern.h
  vendor/nvi/dist/vi/getc.c
  vendor/nvi/dist/vi/v_at.c
  vendor/nvi/dist/vi/v_ch.c
  vendor/nvi/dist/vi/v_delete.c
  vendor/nvi/dist/vi/v_ex.c
  vendor/nvi/dist/vi/v_increment.c
  vendor/nvi/dist/vi/v_init.c
  vendor/nvi/dist/vi/v_itxt.c
  vendor/nvi/dist/vi/v_left.c
  vendor/nvi/dist/vi/v_mark.c
  vendor/nvi/dist/vi/v_match.c
  vendor/nvi/dist/vi/v_paragraph.c
  vendor/nvi/dist/vi/v_put.c
  vendor/nvi/dist/vi/v_redraw.c
  vendor/nvi/dist/vi/v_replace.c
  vendor/nvi/dist/vi/v_right.c
  vendor/nvi/dist/vi/v_screen.c
  vendor/nvi/dist/vi/v_scroll.c
  vendor/nvi/dist/vi/v_search.c
  vendor/nvi/dist/vi/v_section.c
  vendor/nvi/dist/vi/v_sentence.c
  vendor/nvi/dist/vi/v_status.c
  vendor/nvi/dist/vi/v_txt.c
  vendor/nvi/dist/vi/v_ulcase.c
  vendor/nvi/dist/vi/v_undo.c
  vendor/nvi/dist/vi/v_util.c
  vendor/nvi/dist/vi/v_word.c
  vendor/nvi/dist/vi/v_xchar.c
  vendor/nvi/dist/vi/v_yank.c
  vendor/nvi/dist/vi/v_z.c
  vendor/nvi/dist/vi/v_zexit.c
  vendor/nvi/dist/vi/vi.c
  vendor/nvi/dist/vi/vi.h
  vendor/nvi/dist/vi/vs_line.c
  vendor/nvi/dist/vi/vs_msg.c
  vendor/nvi/dist/vi/vs_refresh.c
  vendor/nvi/dist/vi/vs_relative.c
  vendor/nvi/dist/vi/vs_smap.c
  vendor/nvi/dist/vi/vs_split.c

Modified: vendor/nvi/dist/README
==============================================================================
--- vendor/nvi/dist/README	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/README	Fri Apr 10 13:26:05 2015	(r281368)
@@ -1,6 +1,6 @@
-#	$Id: README,v 9.1 2013/11/02 02:50:23 zy Exp $
+#	$Id: README,v 9.2 2015/04/08 17:18:56 zy Exp $
 
-This is version 2.1.2 (2012-11-02) of nex/nvi, a reimplementation of the ex/vi
+This is version 2.1.3 (2015-04-08) of nex/nvi, a reimplementation of the ex/vi
 text editors originally distributed as part of the Fourth Berkeley
 Software Distribution (4BSD), by the University of California, Berkeley.
 

Modified: vendor/nvi/dist/catalog/dump.c
==============================================================================
--- vendor/nvi/dist/catalog/dump.c	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/catalog/dump.c	Fri Apr 10 13:26:05 2015	(r281368)
@@ -10,11 +10,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *	This product includes software developed by the University of
- *	California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
+ * 3. Neither the name of the University nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
  *
@@ -32,12 +28,6 @@
  */
 
 #ifndef lint
-static char copyright[] =
-"@(#) Copyright (c) 1992, 1993, 1994\n\
-	The Regents of the University of California.  All rights reserved.\n";
-#endif /* not lint */
-
-#ifndef lint
 static char sccsid[] = "$Id: dump.c,v 8.2 2011/07/14 00:05:25 zy Exp $";
 #endif /* not lint */
 
@@ -45,8 +35,7 @@ static char sccsid[] = "$Id: dump.c,v 8.
 #include <stdio.h>
 
 static void
-parse(fp)
-	FILE *fp;
+parse(FILE *fp)
 {
 	int ch, s1, s2, s3;
 
@@ -96,9 +85,7 @@ parse(fp)
 }
 
 int
-main(argc, argv)
-	int argc;
-	char *argv[];
+main(int argc, char *argv[])
 {
 	FILE *fp;
 

Modified: vendor/nvi/dist/cl/cl.h
==============================================================================
--- vendor/nvi/dist/cl/cl.h	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/cl/cl.h	Fri Apr 10 13:26:05 2015	(r281368)
@@ -80,16 +80,4 @@ typedef enum { INP_OK=0, INP_EOF, INP_ER
 #define	RCNO(sp, cno)	(cno)
 #define	RLNO(sp, lno)	(lno)
 
-/*
- * XXX
- * Some implementations of curses.h don't define these for us.  Used for
- * compatibility only.
- */
-#ifndef TRUE
-#define	TRUE	1
-#endif
-#ifndef FALSE
-#define	FALSE	0
-#endif
-
 #include "extern.h"

Modified: vendor/nvi/dist/cl/cl_funcs.c
==============================================================================
--- vendor/nvi/dist/cl/cl_funcs.c	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/cl/cl_funcs.c	Fri Apr 10 13:26:05 2015	(r281368)
@@ -33,7 +33,7 @@ static const char sccsid[] = "$Id: cl_fu
 #include "../vi/vi.h"
 #include "cl.h"
 
-static void cl_rdiv __P((SCR *));
+static void cl_rdiv(SCR *);
 
 static int 
 addstr4(SCR *sp, void *str, size_t len, int wide)
@@ -76,31 +76,31 @@ addstr4(SCR *sp, void *str, size_t len, 
  * cl_waddstr --
  *	Add len bytes from the string at the cursor, advancing the cursor.
  *
- * PUBLIC: int cl_waddstr __P((SCR *, const CHAR_T *, size_t));
+ * PUBLIC: int cl_waddstr(SCR *, const CHAR_T *, size_t);
  */
 int
 cl_waddstr(SCR *sp, const CHAR_T *str, size_t len)
 {
-    return addstr4(sp, (void *)str, len, 1);
+	return addstr4(sp, (void *)str, len, 1);
 }
 
 /*
  * cl_addstr --
  *	Add len bytes from the string at the cursor, advancing the cursor.
  *
- * PUBLIC: int cl_addstr __P((SCR *, const char *, size_t));
+ * PUBLIC: int cl_addstr(SCR *, const char *, size_t);
  */
 int
 cl_addstr(SCR *sp, const char *str, size_t len)
 {
-    return addstr4(sp, (void *)str, len, 0);
+	return addstr4(sp, (void *)str, len, 0);
 }
 
 /*
  * cl_attr --
  *	Toggle a screen attribute on/off.
  *
- * PUBLIC: int cl_attr __P((SCR *, scr_attr_t, int));
+ * PUBLIC: int cl_attr(SCR *, scr_attr_t, int);
  */
 int
 cl_attr(SCR *sp, scr_attr_t attribute, int on)
@@ -187,7 +187,7 @@ cl_attr(SCR *sp, scr_attr_t attribute, i
  * cl_baud --
  *	Return the baud rate.
  *
- * PUBLIC: int cl_baud __P((SCR *, u_long *));
+ * PUBLIC: int cl_baud(SCR *, u_long *);
  */
 int
 cl_baud(SCR *sp, u_long *ratep)
@@ -228,7 +228,7 @@ cl_baud(SCR *sp, u_long *ratep)
  * cl_bell --
  *	Ring the bell/flash the screen.
  *
- * PUBLIC: int cl_bell __P((SCR *));
+ * PUBLIC: int cl_bell(SCR *);
  */
 int
 cl_bell(SCR *sp)
@@ -252,7 +252,7 @@ cl_bell(SCR *sp)
  * cl_clrtoeol --
  *	Clear from the current cursor to the end of the line.
  *
- * PUBLIC: int cl_clrtoeol __P((SCR *));
+ * PUBLIC: int cl_clrtoeol(SCR *);
  */
 int
 cl_clrtoeol(SCR *sp)
@@ -281,7 +281,7 @@ cl_clrtoeol(SCR *sp)
  * cl_cursor --
  *	Return the current cursor position.
  *
- * PUBLIC: int cl_cursor __P((SCR *, size_t *, size_t *));
+ * PUBLIC: int cl_cursor(SCR *, size_t *, size_t *);
  */
 int
 cl_cursor(SCR *sp, size_t *yp, size_t *xp)
@@ -307,7 +307,7 @@ cl_cursor(SCR *sp, size_t *yp, size_t *x
  * cl_deleteln --
  *	Delete the current line, scrolling all lines below it.
  *
- * PUBLIC: int cl_deleteln __P((SCR *));
+ * PUBLIC: int cl_deleteln(SCR *);
  */
 int
 cl_deleteln(SCR *sp)
@@ -344,7 +344,7 @@ cl_deleteln(SCR *sp)
  * cl_discard --
  *	Discard a screen.
  *
- * PUBLIC: int cl_discard __P((SCR *, SCR **));
+ * PUBLIC: int cl_discard(SCR *, SCR **);
  */
 int
 cl_discard(SCR *discardp, SCR **acquirep)
@@ -385,7 +385,7 @@ cl_discard(SCR *discardp, SCR **acquirep
  *	Adjust the screen for ex.  This routine is purely for standalone
  *	ex programs.  All special purpose, all special case.
  *
- * PUBLIC: int cl_ex_adjust __P((SCR *, exadj_t));
+ * PUBLIC: int cl_ex_adjust(SCR *, exadj_t);
  */
 int
 cl_ex_adjust(SCR *sp, exadj_t action)
@@ -440,7 +440,7 @@ cl_ex_adjust(SCR *sp, exadj_t action)
  * cl_insertln --
  *	Push down the current line, discarding the bottom line.
  *
- * PUBLIC: int cl_insertln __P((SCR *));
+ * PUBLIC: int cl_insertln(SCR *);
  */
 int
 cl_insertln(SCR *sp)
@@ -458,7 +458,7 @@ cl_insertln(SCR *sp)
  * cl_keyval --
  *	Return the value for a special key.
  *
- * PUBLIC: int cl_keyval __P((SCR *, scr_keyval_t, CHAR_T *, int *));
+ * PUBLIC: int cl_keyval(SCR *, scr_keyval_t, CHAR_T *, int *);
  */
 int
 cl_keyval(SCR *sp, scr_keyval_t val, CHAR_T *chp, int *dnep)
@@ -496,7 +496,7 @@ cl_keyval(SCR *sp, scr_keyval_t val, CHA
  * cl_move --
  *	Move the cursor.
  *
- * PUBLIC: int cl_move __P((SCR *, size_t, size_t));
+ * PUBLIC: int cl_move(SCR *, size_t, size_t);
  */
 int
 cl_move(SCR *sp, size_t lno, size_t cno)
@@ -516,7 +516,7 @@ cl_move(SCR *sp, size_t lno, size_t cno)
  * cl_refresh --
  *	Refresh the screen.
  *
- * PUBLIC: int cl_refresh __P((SCR *, int));
+ * PUBLIC: int cl_refresh(SCR *, int);
  */
 int
 cl_refresh(SCR *sp, int repaint)
@@ -599,7 +599,7 @@ cl_rdiv(SCR *sp)
  * cl_rename --
  *	Rename the file.
  *
- * PUBLIC: int cl_rename __P((SCR *, char *, int));
+ * PUBLIC: int cl_rename(SCR *, char *, int);
  */
 int
 cl_rename(SCR *sp, char *name, int on)
@@ -621,7 +621,7 @@ cl_rename(SCR *sp, char *name, int on)
 	if (on) {
 		clp->focus = sp;
 		if (!F_ISSET(clp, CL_RENAME_OK) ||
-				strncmp(OG_STR(gp, GO_TERM), "xterm", 5))
+		    strncmp(OG_STR(gp, GO_TERM), "xterm", 5))
 			return (0);
 
 		if (clp->oname == NULL && (wid = getenv("WINDOWID"))) {
@@ -654,7 +654,7 @@ rename:		cl_setname(gp, name);
  * cl_setname --
  *	Set a X11 icon/window name.
  *
- * PUBLIC: void cl_setname __P((GS *, char *));
+ * PUBLIC: void cl_setname(GS *, char *);
  */
 void
 cl_setname(GS *gp, char *name)
@@ -671,7 +671,7 @@ cl_setname(GS *gp, char *name)
  * cl_split --
  *	Split a screen.
  *
- * PUBLIC: int cl_split __P((SCR *, SCR *));
+ * PUBLIC: int cl_split(SCR *, SCR *);
  */
 int
 cl_split(SCR *origp, SCR *newp)
@@ -697,7 +697,7 @@ cl_split(SCR *origp, SCR *newp)
  * cl_suspend --
  *	Suspend a screen.
  *
- * PUBLIC: int cl_suspend __P((SCR *, int *));
+ * PUBLIC: int cl_suspend(SCR *, int *);
  */
 int
 cl_suspend(SCR *sp, int *allowedp)
@@ -825,7 +825,7 @@ cl_suspend(SCR *sp, int *allowedp)
  * cl_usage --
  *	Print out the curses usage messages.
  * 
- * PUBLIC: void cl_usage __P((void));
+ * PUBLIC: void cl_usage(void);
  */
 void
 cl_usage(void)

Modified: vendor/nvi/dist/cl/cl_main.c
==============================================================================
--- vendor/nvi/dist/cl/cl_main.c	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/cl/cl_main.c	Fri Apr 10 13:26:05 2015	(r281368)
@@ -10,7 +10,7 @@
 #include "config.h"
 
 #ifndef lint
-static const char sccsid[] = "$Id: cl_main.c,v 10.55 2011/08/15 19:52:28 zy Exp $";
+static const char sccsid[] = "$Id: cl_main.c,v 10.56 2015/04/05 06:20:53 zy Exp $";
 #endif /* not lint */
 
 #include <sys/types.h>
@@ -36,20 +36,20 @@ static const char sccsid[] = "$Id: cl_ma
 GS *__global_list;				/* GLOBAL: List of screens. */
 sigset_t __sigblockset;				/* GLOBAL: Blocked signals. */
 
-static void	   cl_func_std __P((GS *));
-static CL_PRIVATE *cl_init __P((GS *));
-static GS	  *gs_init __P((char *));
-static void	   perr __P((char *, char *));
-static int	   setsig __P((int, struct sigaction *, void (*)(int)));
-static void	   sig_end __P((GS *));
-static void	   term_init __P((char *, char *));
+static void	   cl_func_std(GS *);
+static CL_PRIVATE *cl_init(GS *);
+static GS	  *gs_init(char *);
+static void	   perr(char *, char *);
+static int	   setsig(int, struct sigaction *, void (*)(int));
+static void	   sig_end(GS *);
+static void	   term_init(char *, char *);
 
 /*
  * main --
  *	This is the main loop for the standalone curses editor.
  */
 int
-main(int argc, char **argv)
+main(int argc, char *argv[])
 {
 	static int reenter;
 	CL_PRIVATE *clp;
@@ -92,7 +92,7 @@ main(int argc, char **argv)
 	 * have to use termcap/terminfo to find out how big the screen is.
 	 */
 	if ((ttype = getenv("TERM")) == NULL)
-		ttype = "unknown";
+		ttype = "ansi";
 	term_init(gp->progname, ttype);
 
 	/* Add the terminal type to the global structure. */
@@ -146,7 +146,7 @@ main(int argc, char **argv)
 	}
 
 	/* Free the global and CL private areas. */
-#if defined(DEBUG) || defined(PURIFY) || defined(LIBRARY)
+#if defined(DEBUG) || defined(PURIFY)
 	if (clp->oname != NULL)
 		free(clp->oname);
 	free(clp);
@@ -292,7 +292,7 @@ h_winch(int signo)
  * sig_init --
  *	Initialize signals.
  *
- * PUBLIC: int sig_init __P((GS *, SCR *));
+ * PUBLIC: int sig_init(GS *, SCR *);
  */
 int
 sig_init(GS *gp, SCR *sp)
@@ -337,7 +337,7 @@ sig_init(GS *gp, SCR *sp)
  *	Set a signal handler.
  */
 static int
-setsig(int signo, struct sigaction *oactp, void (*handler) (int))
+setsig(int signo, struct sigaction *oactp, void (*handler)(int))
 {
 	struct sigaction act;
 
@@ -345,21 +345,12 @@ setsig(int signo, struct sigaction *oact
 	 * Use sigaction(2), not signal(3), since we don't always want to
 	 * restart system calls.  The example is when waiting for a command
 	 * mode keystroke and SIGWINCH arrives.  Besides, you can't portably
-	 * restart system calls (thanks, POSIX!).  On the other hand, you
-	 * can't portably NOT restart system calls (thanks, Sun!).  SunOS
-	 * used SA_INTERRUPT as their extension to NOT restart read calls.
-	 * We sure hope nobody else used it for anything else.  Mom told me
-	 * there'd be days like this.  She just never told me that there'd
-	 * be so many.
+	 * restart system calls (thanks, POSIX!).
 	 */
 	act.sa_handler = handler;
 	sigemptyset(&act.sa_mask);
 
-#ifdef SA_INTERRUPT
-	act.sa_flags = SA_INTERRUPT;
-#else
 	act.sa_flags = 0;
-#endif
 	return (sigaction(signo, &act, oactp));
 }
 

Modified: vendor/nvi/dist/cl/cl_read.c
==============================================================================
--- vendor/nvi/dist/cl/cl_read.c	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/cl/cl_read.c	Fri Apr 10 13:26:05 2015	(r281368)
@@ -35,15 +35,15 @@ static const char sccsid[] = "$Id: cl_re
 #undef columns
 #undef lines  
 
-static input_t	cl_read __P((SCR *,
-    u_int32_t, char *, size_t, int *, struct timeval *));
-static int	cl_resize __P((SCR *, size_t, size_t));
+static input_t	cl_read(SCR *,
+    u_int32_t, char *, size_t, int *, struct timeval *);
+static int	cl_resize(SCR *, size_t, size_t);
 
 /*
  * cl_event --
  *	Return a single event.
  *
- * PUBLIC: int cl_event __P((SCR *, EVENT *, u_int32_t, int));
+ * PUBLIC: int cl_event(SCR *, EVENT *, u_int32_t, int);
  */
 int
 cl_event(SCR *sp, EVENT *evp, u_int32_t flags, int ms)
@@ -143,7 +143,8 @@ read:
  *	Read characters from the input.
  */
 static input_t
-cl_read(SCR *sp, u_int32_t flags, char *bp, size_t blen, int *nrp, struct timeval *tp)
+cl_read(SCR *sp, u_int32_t flags, char *bp, size_t blen, int *nrp,
+    struct timeval *tp)
 {
 	struct termios term1, term2;
 	CL_PRIVATE *clp;

Modified: vendor/nvi/dist/cl/cl_screen.c
==============================================================================
--- vendor/nvi/dist/cl/cl_screen.c	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/cl/cl_screen.c	Fri Apr 10 13:26:05 2015	(r281368)
@@ -10,7 +10,7 @@
 #include "config.h"
 
 #ifndef lint
-static const char sccsid[] = "$Id: cl_screen.c,v 10.56 2002/05/03 19:59:44 skimo Exp $";
+static const char sccsid[] = "$Id: cl_screen.c,v 10.58 2015/04/08 02:12:11 zy Exp $";
 #endif /* not lint */
 
 #include <sys/types.h>
@@ -32,18 +32,18 @@ static const char sccsid[] = "$Id: cl_sc
 #include "../common/common.h"
 #include "cl.h"
 
-static int	cl_ex_end __P((GS *));
-static int	cl_ex_init __P((SCR *));
-static void	cl_freecap __P((CL_PRIVATE *));
-static int	cl_vi_end __P((GS *));
-static int	cl_vi_init __P((SCR *));
-static int	cl_putenv __P((char *, char *, u_long));
+static int	cl_ex_end(GS *);
+static int	cl_ex_init(SCR *);
+static void	cl_freecap(CL_PRIVATE *);
+static int	cl_vi_end(GS *);
+static int	cl_vi_init(SCR *);
+static int	cl_putenv(char *, char *, u_long);
 
 /*
  * cl_screen --
  *	Switch screen types.
  *
- * PUBLIC: int cl_screen __P((SCR *, u_int32_t));
+ * PUBLIC: int cl_screen(SCR *, u_int32_t);
  */
 int
 cl_screen(SCR *sp, u_int32_t flags)
@@ -58,11 +58,9 @@ cl_screen(SCR *sp, u_int32_t flags)
 
 	/* See if the current information is incorrect. */
 	if (F_ISSET(gp, G_SRESTART)) {
-		if (CLSP(sp)) {
-		    delwin(CLSP(sp));
-		    sp->cl_private = NULL;
-		}
-		if (cl_quit(gp))
+		if ((!F_ISSET(sp, SC_SCR_EX | SC_SCR_VI) ||
+		     resizeterm(O_VAL(sp, O_LINES), O_VAL(sp, O_COLUMNS))) &&
+		    cl_quit(gp))
 			return (1);
 		F_CLR(gp, G_SRESTART);
 	}
@@ -131,7 +129,7 @@ cl_screen(SCR *sp, u_int32_t flags)
  * cl_quit --
  *	Shutdown the screens.
  *
- * PUBLIC: int cl_quit __P((GS *));
+ * PUBLIC: int cl_quit(GS *);
  */
 int
 cl_quit(GS *gp)
@@ -234,20 +232,15 @@ cl_vi_init(SCR *sp)
 	cl_putenv("COLUMNS", NULL, (u_long)O_VAL(sp, O_COLUMNS));
 
 	/*
-	 * We don't care about the SCREEN reference returned by newterm, we
-	 * never have more than one SCREEN at a time.
-	 *
-	 * XXX
-	 * The SunOS initscr() can't be called twice.  Don't even think about
-	 * using it.  It fails in subtle ways (e.g. select(2) on fileno(stdin)
-	 * stops working).  (The SVID notes that applications should only call
-	 * initscr() once.)
-	 *
-	 * XXX
-	 * The HP/UX newterm doesn't support the NULL first argument, so we
-	 * have to specify the terminal type.
+	 * The terminal is aways initialized, either in `main`, or by a
+	 * previous call to newterm(3X).
 	 */
 	(void)del_curterm(cur_term);
+
+	/*
+	 * We never have more than one SCREEN at a time, so set_term(NULL) will
+	 * give us the last SCREEN.
+	 */
 	errno = 0;
 	if (newterm(ttype, stdout, stdin) == NULL) {
 		if (errno)
@@ -416,6 +409,9 @@ cl_vi_end(GS *gp)
 	/* End curses window. */
 	(void)endwin();
 
+	/* Free the SCREEN created by newterm(3X). */
+	delscreen(set_term(NULL));
+
 	/*
 	 * XXX
 	 * The screen TE sequence just got sent.  See the comment in
@@ -520,7 +516,7 @@ cl_ex_end(GS *gp)
  * cl_getcap --
  *	Retrieve termcap/terminfo strings.
  *
- * PUBLIC: int cl_getcap __P((SCR *, char *, char **));
+ * PUBLIC: int cl_getcap(SCR *, char *, char **);
  */
 int
 cl_getcap(SCR *sp, char *name, char **elementp)

Modified: vendor/nvi/dist/cl/cl_term.c
==============================================================================
--- vendor/nvi/dist/cl/cl_term.c	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/cl/cl_term.c	Fri Apr 10 13:26:05 2015	(r281368)
@@ -10,7 +10,7 @@
 #include "config.h"
 
 #ifndef lint
-static const char sccsid[] = "$Id: cl_term.c,v 10.34 2013/12/07 16:21:14 wjenkner Exp $";
+static const char sccsid[] = "$Id: cl_term.c,v 10.35 2015/04/08 02:12:11 zy Exp $";
 #endif /* not lint */
 
 #include <sys/types.h>
@@ -34,7 +34,7 @@ static const char sccsid[] = "$Id: cl_te
 #include "../common/common.h"
 #include "cl.h"
 
-static int cl_pfmap __P((SCR *, seq_t, CHAR_T *, size_t, CHAR_T *, size_t));
+static int cl_pfmap(SCR *, seq_t, CHAR_T *, size_t, CHAR_T *, size_t);
 
 /*
  * XXX
@@ -81,7 +81,7 @@ static TKLIST const m2_tklist[] = {	/* I
  * cl_term_init --
  *	Initialize the special keys defined by the termcap/terminfo entry.
  *
- * PUBLIC: int cl_term_init __P((SCR *));
+ * PUBLIC: int cl_term_init(SCR *);
  */
 int
 cl_term_init(SCR *sp)
@@ -182,7 +182,7 @@ cl_term_init(SCR *sp)
  * cl_term_end --
  *	End the special keys defined by the termcap/terminfo entry.
  *
- * PUBLIC: int cl_term_end __P((GS *));
+ * PUBLIC: int cl_term_end(GS *);
  */
 int
 cl_term_end(GS *gp)
@@ -206,7 +206,7 @@ cl_term_end(GS *gp)
  * cl_fmap --
  *	Map a function key.
  *
- * PUBLIC: int cl_fmap __P((SCR *, seq_t, CHAR_T *, size_t, CHAR_T *, size_t));
+ * PUBLIC: int cl_fmap(SCR *, seq_t, CHAR_T *, size_t, CHAR_T *, size_t);
  */
 int
 cl_fmap(SCR *sp, seq_t stype, CHAR_T *from, size_t flen, CHAR_T *to, size_t tlen)
@@ -258,7 +258,7 @@ cl_pfmap(SCR *sp, seq_t stype, CHAR_T *f
  * cl_optchange --
  *	Curses screen specific "option changed" routine.
  *
- * PUBLIC: int cl_optchange __P((SCR *, int, char *, u_long *));
+ * PUBLIC: int cl_optchange(SCR *, int, char *, u_long *);
  */
 int
 cl_optchange(SCR *sp, int opt, char *str, u_long *valp)
@@ -268,15 +268,16 @@ cl_optchange(SCR *sp, int opt, char *str
 	clp = CLP(sp);
 
 	switch (opt) {
+	case O_TERM:
+		F_CLR(sp, SC_SCR_EX | SC_SCR_VI);
+		/* FALLTHROUGH */
 	case O_COLUMNS:
 	case O_LINES:
-	case O_TERM:
 		/*
-		 * Changing the columns, lines or terminal require that
-		 * we restart the screen.
+		 * Changing the terminal type requires that we reinitialize
+		 * curses, while resizing does not.
 		 */
 		F_SET(sp->gp, G_SRESTART);
-		F_CLR(sp, SC_SCR_EX | SC_SCR_VI);
 		break;
 	case O_MESG:
 		(void)cl_omesg(sp, clp, *valp);
@@ -305,7 +306,7 @@ cl_optchange(SCR *sp, int opt, char *str
  * cl_omesg --
  *	Turn the tty write permission on or off.
  *
- * PUBLIC: int cl_omesg __P((SCR *, CL_PRIVATE *, int));
+ * PUBLIC: int cl_omesg(SCR *, CL_PRIVATE *, int);
  */
 int
 cl_omesg(SCR *sp, CL_PRIVATE *clp, int on)
@@ -351,7 +352,7 @@ cl_omesg(SCR *sp, CL_PRIVATE *clp, int o
  * cl_ssize --
  *	Return the terminal size.
  *
- * PUBLIC: int cl_ssize __P((SCR *, int, size_t *, size_t *, int *));
+ * PUBLIC: int cl_ssize(SCR *, int, size_t *, size_t *, int *);
  */
 int
 cl_ssize(SCR *sp, int sigwinch, size_t *rowp, size_t *colp, int *changedp)
@@ -467,7 +468,7 @@ noterm:	if (row == 0)
  * cl_putchar --
  *	Function version of putchar, for tputs.
  *
- * PUBLIC: int cl_putchar __P((int));
+ * PUBLIC: int cl_putchar(int);
  */
 int
 cl_putchar(int ch)

Modified: vendor/nvi/dist/cl/extern.h
==============================================================================
--- vendor/nvi/dist/cl/extern.h	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/cl/extern.h	Fri Apr 10 13:26:05 2015	(r281368)
@@ -1,31 +1,31 @@
-int cl_waddstr __P((SCR *, const CHAR_T *, size_t));
-int cl_addstr __P((SCR *, const char *, size_t));
-int cl_attr __P((SCR *, scr_attr_t, int));
-int cl_baud __P((SCR *, u_long *));
-int cl_bell __P((SCR *));
-int cl_clrtoeol __P((SCR *));
-int cl_cursor __P((SCR *, size_t *, size_t *));
-int cl_deleteln __P((SCR *));
-int cl_discard __P((SCR *, SCR **));
-int cl_ex_adjust __P((SCR *, exadj_t));
-int cl_insertln __P((SCR *));
-int cl_keyval __P((SCR *, scr_keyval_t, CHAR_T *, int *));
-int cl_move __P((SCR *, size_t, size_t));
-int cl_refresh __P((SCR *, int));
-int cl_rename __P((SCR *, char *, int));
-void cl_setname __P((GS *, char *));
-int cl_split __P((SCR *, SCR *));
-int cl_suspend __P((SCR *, int *));
-void cl_usage __P((void));
-int sig_init __P((GS *, SCR *));
-int cl_event __P((SCR *, EVENT *, u_int32_t, int));
-int cl_screen __P((SCR *, u_int32_t));
-int cl_quit __P((GS *));
-int cl_getcap __P((SCR *, char *, char **));
-int cl_term_init __P((SCR *));
-int cl_term_end __P((GS *));
-int cl_fmap __P((SCR *, seq_t, CHAR_T *, size_t, CHAR_T *, size_t));
-int cl_optchange __P((SCR *, int, char *, u_long *));
-int cl_omesg __P((SCR *, CL_PRIVATE *, int));
-int cl_ssize __P((SCR *, int, size_t *, size_t *, int *));
-int cl_putchar __P((int));
+int cl_waddstr(SCR *, const CHAR_T *, size_t);
+int cl_addstr(SCR *, const char *, size_t);
+int cl_attr(SCR *, scr_attr_t, int);
+int cl_baud(SCR *, u_long *);
+int cl_bell(SCR *);
+int cl_clrtoeol(SCR *);
+int cl_cursor(SCR *, size_t *, size_t *);
+int cl_deleteln(SCR *);
+int cl_discard(SCR *, SCR **);
+int cl_ex_adjust(SCR *, exadj_t);
+int cl_insertln(SCR *);
+int cl_keyval(SCR *, scr_keyval_t, CHAR_T *, int *);
+int cl_move(SCR *, size_t, size_t);
+int cl_refresh(SCR *, int);
+int cl_rename(SCR *, char *, int);
+void cl_setname(GS *, char *);
+int cl_split(SCR *, SCR *);
+int cl_suspend(SCR *, int *);
+void cl_usage(void);
+int sig_init(GS *, SCR *);
+int cl_event(SCR *, EVENT *, u_int32_t, int);
+int cl_screen(SCR *, u_int32_t);
+int cl_quit(GS *);
+int cl_getcap(SCR *, char *, char **);
+int cl_term_init(SCR *);
+int cl_term_end(GS *);
+int cl_fmap(SCR *, seq_t, CHAR_T *, size_t, CHAR_T *, size_t);
+int cl_optchange(SCR *, int, char *, u_long *);
+int cl_omesg(SCR *, CL_PRIVATE *, int);
+int cl_ssize(SCR *, int, size_t *, size_t *, int *);
+int cl_putchar(int);

Modified: vendor/nvi/dist/common/common.h
==============================================================================
--- vendor/nvi/dist/common/common.h	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/common/common.h	Fri Apr 10 13:26:05 2015	(r281368)
@@ -23,8 +23,8 @@
  */
 typedef struct _cb		CB;
 typedef struct _csc		CSC;
-typedef struct _conv	    	CONV;
-typedef struct _conv_win    	CONVWIN;
+typedef struct _conv		CONV;
+typedef struct _conv_win	CONVWIN;
 typedef struct _event		EVENT;
 typedef struct _excmd		EXCMD;
 typedef struct _exf		EXF;

Modified: vendor/nvi/dist/common/conv.c
==============================================================================
--- vendor/nvi/dist/common/conv.c	Fri Apr 10 13:20:31 2015	(r281367)
+++ vendor/nvi/dist/common/conv.c	Fri Apr 10 13:26:05 2015	(r281368)
@@ -12,7 +12,7 @@
 #include "config.h"
 
 #ifndef lint
-static const char sccsid[] = "$Id: conv.c,v 2.39 2013/07/01 23:28:13 zy Exp $";
+static const char sccsid[] = "$Id: conv.c,v 2.40 2014/02/27 16:25:29 zy Exp $";
 #endif /* not lint */
 
 #include <sys/types.h>
@@ -36,35 +36,37 @@ static const char sccsid[] = "$Id: conv.
  * codeset --
  *	Get the locale encoding.
  *
- * PUBLIC: char * codeset __P((void));
+ * PUBLIC: char * codeset(void);
  */
 char *
-codeset(void) {
-    static char *cs;
+codeset(void)
+{
+	static char *cs;
+
+	if (cs == NULL)
+		cs = nl_langinfo(CODESET);
 
-    if (cs == NULL)
-	cs = nl_langinfo(CODESET);
-    return cs;
+	return cs;
 }
 
 #ifdef USE_WIDECHAR
 static int 
-raw2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw,
-	size_t *tolen, CHAR_T **dst)
+raw2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, size_t *tolen,
+    CHAR_T **dst)
 {
-    int i;
-    CHAR_T **tostr = &cw->bp1.wc;
-    size_t  *blen = &cw->blen1;
+	int i;
+	CHAR_T **tostr = &cw->bp1.wc;
+	size_t  *blen = &cw->blen1;
 
-    BINC_RETW(NULL, *tostr, *blen, len);
+	BINC_RETW(NULL, *tostr, *blen, len);
 
-    *tolen = len;
-    for (i = 0; i < len; ++i)
-	(*tostr)[i] = (u_char) str[i];
+	*tolen = len;
+	for (i = 0; i < len; ++i)
+		(*tostr)[i] = (u_char) str[i];
 
-    *dst = cw->bp1.wc;
+	*dst = cw->bp1.wc;
 
-    return 0;
+	return 0;
 }
 
 #define CONV_BUFFER_SIZE    512
@@ -73,27 +75,27 @@ raw2int(SCR *sp, const char * str, ssize
  * len contains the number of bytes put in the buffer
  */
 #ifdef USE_ICONV
-#define CONVERT(str, left, src, len)				    	\
-    do {								\
-	size_t outleft;							\
-	char *bp = buffer;						\
-	outleft = CONV_BUFFER_SIZE;					\
-	errno = 0;							\
-	if (iconv(id, (iconv_src_t)&str, &left, &bp, &outleft) == -1 &&	\
-		errno != E2BIG)						\
-	    goto err;							\
-	if ((len = CONV_BUFFER_SIZE - outleft) == 0) {			\
-	    error = -left;						\
-	    goto err;							\
-	}				    				\
-	src = buffer;							\
-    } while (0)
+#define CONVERT(str, left, src, len)					\
+	do {								\
+		size_t outleft;						\
+		char *bp = buffer;					\
+		outleft = CONV_BUFFER_SIZE;				\
+		errno = 0;						\
+		if (iconv(id, (iconv_src_t)&str, &left, &bp, &outleft)	\
+		    == -1 && errno != E2BIG)				\
+			goto err;					\
+		if ((len = CONV_BUFFER_SIZE - outleft) == 0) {		\
+			error = -left;					\
+			goto err;					\
+		}							\
+		src = buffer;						\
+	} while (0)
 
 #define IC_RESET()							\
-    do {								\
-	if (id != (iconv_t)-1)						\
-	    iconv(id, NULL, NULL, NULL, NULL);				\
-    } while(0)
+	do {								\
+		if (id != (iconv_t)-1)					\
+			iconv(id, NULL, NULL, NULL, NULL);		\
+	} while(0)
 #else
 #define CONVERT(str, left, src, len)
 #define IC_RESET()
@@ -101,114 +103,116 @@ raw2int(SCR *sp, const char * str, ssize
 
 static int 
 default_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, 
-		size_t *tolen, CHAR_T **dst, iconv_t id)
+    size_t *tolen, CHAR_T **dst, iconv_t id)
 {
-    size_t i = 0, j;
-    CHAR_T **tostr = &cw->bp1.wc;
-    size_t  *blen = &cw->blen1;
-    mbstate_t mbs;
-    size_t   n;
-    ssize_t  nlen = len;
-    char *src = (char *)str;
+	size_t i = 0, j;
+	CHAR_T **tostr = &cw->bp1.wc;
+	size_t *blen = &cw->blen1;
+	mbstate_t mbs;
+	size_t n;
+	ssize_t nlen = len;
+	char *src = (char *)str;
 #ifdef USE_ICONV
-    char	buffer[CONV_BUFFER_SIZE];
+	char buffer[CONV_BUFFER_SIZE];
 #endif
-    size_t	left = len;
-    int		error = 1;
+	size_t left = len;
+	int error = 1;
 
-    BZERO(&mbs, 1);
-    BINC_RETW(NULL, *tostr, *blen, nlen);
+	BZERO(&mbs, 1);
+	BINC_RETW(NULL, *tostr, *blen, nlen);
 
 #ifdef USE_ICONV
-    if (id != (iconv_t)-1)
-	CONVERT(str, left, src, len);
+	if (id != (iconv_t)-1)
+		CONVERT(str, left, src, len);
 #endif
 
-    for (i = 0, j = 0; j < len; ) {
-	n = mbrtowc((*tostr)+i, src+j, len-j, &mbs);
-	/* NULL character converted */
-	if (n == -2) error = -(len-j);
-	if (n == -1 || n == -2) goto err;
-	if (n == 0) n = 1;
-	j += n;
-	if (++i >= *blen) {
-	    nlen += 256;
-	    BINC_RETW(NULL, *tostr, *blen, nlen);
-	}
-	if (id != (iconv_t)-1 && j == len && left) {
-	    CONVERT(str, left, src, len);
-	    j = 0;
+	for (i = 0, j = 0; j < len; ) {
+		n = mbrtowc((*tostr)+i, src+j, len-j, &mbs);
+		/* NULL character converted */
+		if (n == -2)
+			error = -(len-j);
+		if (n == -1 || n == -2)
+			goto err;
+		if (n == 0)
+			n = 1;
+		j += n;
+		if (++i >= *blen) {
+			nlen += 256;
+			BINC_RETW(NULL, *tostr, *blen, nlen);
+		}
+		if (id != (iconv_t)-1 && j == len && left) {
+			CONVERT(str, left, src, len);
+			j = 0;
+		}
 	}
-    }
 
-    error = 0;
+	error = 0;
 err:
-    *tolen = i;
-    *dst = cw->bp1.wc;
-    IC_RESET();
+	*tolen = i;
+	*dst = cw->bp1.wc;
+	IC_RESET();
 
-    return error;
+	return error;
 }
 
 static int 
-fe_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, 
-	    size_t *tolen, CHAR_T **dst)
+fe_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, size_t *tolen,
+    CHAR_T **dst)
 {
-    return default_char2int(sp, str, len, cw, tolen, dst,
-	sp->conv.id[IC_FE_CHAR2INT]);
+	return default_char2int(sp, str, len, cw, tolen, dst,
+	    sp->conv.id[IC_FE_CHAR2INT]);
 }
 
 static int 
-ie_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, 
-	    size_t *tolen, CHAR_T **dst)
+ie_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, size_t *tolen,
+    CHAR_T **dst)
 {
-    return default_char2int(sp, str, len, cw, tolen, dst,
-	sp->conv.id[IC_IE_CHAR2INT]);
+	return default_char2int(sp, str, len, cw, tolen, dst,
+	    sp->conv.id[IC_IE_CHAR2INT]);
 }
 
 static int 
-cs_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, 
-	    size_t *tolen, CHAR_T **dst)
+cs_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, size_t *tolen,
+    CHAR_T **dst)
 {
-    return default_char2int(sp, str, len, cw, tolen, dst,
-	(iconv_t)-1);
+	return default_char2int(sp, str, len, cw, tolen, dst, (iconv_t)-1);
 }
 
 static int 
-int2raw(SCR *sp, const CHAR_T * str, ssize_t len, CONVWIN *cw,
-	size_t *tolen, char **dst)
+int2raw(SCR *sp, const CHAR_T * str, ssize_t len, CONVWIN *cw, size_t *tolen,
+    char **dst)
 {
-    int i;
-    char **tostr = &cw->bp1.c;
-    size_t  *blen = &cw->blen1;
+	int i;
+	char **tostr = &cw->bp1.c;
+	size_t  *blen = &cw->blen1;
 
-    BINC_RETC(NULL, *tostr, *blen, len);
+	BINC_RETC(NULL, *tostr, *blen, len);
 
-    *tolen = len;
-    for (i = 0; i < len; ++i)
-	(*tostr)[i] = str[i];
+	*tolen = len;
+	for (i = 0; i < len; ++i)
+		(*tostr)[i] = str[i];
 
-    *dst = cw->bp1.c;
+	*dst = cw->bp1.c;
 
-    return 0;
+	return 0;
 }
 
 static int 
 default_int2char(SCR *sp, const CHAR_T * str, ssize_t len, CONVWIN *cw, 
-		size_t *tolen, char **pdst, iconv_t id)
+    size_t *tolen, char **pdst, iconv_t id)
 {
-    size_t i, j, offset = 0;
-    char **tostr = &cw->bp1.c;
-    size_t  *blen = &cw->blen1;
-    mbstate_t mbs;
-    size_t n;
-    ssize_t  nlen = len + MB_CUR_MAX;
-    char *dst;
-    size_t buflen;
+	size_t i, j, offset = 0;
+	char **tostr = &cw->bp1.c;
+	size_t *blen = &cw->blen1;
+	mbstate_t mbs;
+	size_t n;
+	ssize_t  nlen = len + MB_CUR_MAX;
+	char *dst;
+	size_t buflen;
 #ifdef USE_ICONV
-    char	buffer[CONV_BUFFER_SIZE];
+	char buffer[CONV_BUFFER_SIZE];
 #endif
-    int		error = 1;
+	int error = 1;
 
 /* convert first len bytes of buffer and append it to cw->bp
  * len is adjusted => 0

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201504101326.t3ADQ6X2098127>