CVS commit: src/usr.bin/wc

2010-02-19 Thread Matthias Scheler
Module Name:src
Committed By:   tron
Date:   Fri Feb 19 11:15:23 UTC 2010

Modified Files:
src/usr.bin/wc: wc.c

Log Message:
Report the number of characters, not the number of bytes in the
longest line.

Problem pointed out by YAMAMOTO Takashi on tech-userlevel mailing list.


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/usr.bin/wc/wc.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/wc/wc.c
diff -u src/usr.bin/wc/wc.c:1.33 src/usr.bin/wc/wc.c:1.34
--- src/usr.bin/wc/wc.c:1.33	Thu Feb 18 10:43:50 2010
+++ src/usr.bin/wc/wc.c	Fri Feb 19 11:15:23 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: wc.c,v 1.33 2010/02/18 10:43:50 tron Exp $	*/
+/*	$NetBSD: wc.c,v 1.34 2010/02/19 11:15:23 tron Exp $	*/
 
 /*
  * Copyright (c) 1980, 1987, 1991, 1993
@@ -39,7 +39,7 @@
 #if 0
 static char sccsid[] = @(#)wc.c	8.2 (Berkeley) 5/2/95;
 #else
-__RCSID($NetBSD: wc.c,v 1.33 2010/02/18 10:43:50 tron Exp $);
+__RCSID($NetBSD: wc.c,v 1.34 2010/02/19 11:15:23 tron Exp $);
 #endif
 #endif /* not lint */
 
@@ -185,7 +185,7 @@
 	wchar_t *WC;
 	const char *name;			/* filename or stdin */
 	size_t r = 0;
-	int fd, gotsp, len = 0;
+	int fd, len = 0;
 
 	linect = wordct = charct = longest = 0;
 	if (file != NULL) {
@@ -200,17 +200,16 @@
 		name = stdin;
 	}
 
-	if (dochar || doword)
-		memset(st, 0, sizeof(st));
+	if (dochar || doword || dolongest)
+		(void)memset(st, 0, sizeof(st));
 
-	if (!doword) {
+	if (!(doword || dolongest)) {
 		/*
 		 * line counting is split out because it's a lot
 		 * faster to get lines than to get words, since
 		 * the word count requires some logic.
 		 */
-		if (doline || dochar || dolongest) {
-			wc_count_t llen = 0;
+		if (doline || dochar) {
 			while ((len = read(fd, buf, MAXBSIZE))  0) {
 if (dochar) {
 	size_t wlen;
@@ -220,16 +219,10 @@
 	charct += wlen;
 } else if (dobyte)
 	charct += len;
-if (doline || dolongest) {
+if (doline) {
 	for (C = buf; len--; ++C) {
-		if (*C == '\n') {
+		if (*C == '\n')
 			++linect;
-			if (llen  longest)
-longest = llen;
-			llen = 0;
-		} else {
-			llen++;
-		}
 	}
 }
 			}
@@ -260,9 +253,11 @@
 		}
 	} else {
 		/* do it the hard way... */
-		wc_count_t llen = 0;
+		wc_count_t linelen;
+bool   gotsp;
 
-		gotsp = 1;
+		linelen = 0;
+		gotsp = true;
 		while ((len = read(fd, buf, MAXBSIZE))  0) {
 			size_t wlen;
 
@@ -275,14 +270,14 @@
 			}
 			for (WC = wbuf; wlen--; ++WC) {
 if (iswspace(*WC)) {
-	gotsp = 1;
+	gotsp = true;
 	if (*WC == L'\n') {
 		++linect;
-		if (llen  longest)
-			longest = llen;
-		llen = 0;
+		if (linelen  longest)
+			longest = linelen;
+		linelen = 0;
 	} else {
-		llen++;
+		linelen++;
 	}
 } else {
 	/*
@@ -294,11 +289,11 @@
 	 * printing or non-printing.
 	 */
 	if (gotsp) {
-		gotsp = 0;
+		gotsp = false;
 		++wordct;
 	}
 
-	llen++;
+	linelen++;
 }
 			}
 		}



CVS commit: src/sys/dev/i2o

2010-02-19 Thread Aleksej Saushev
Module Name:src
Committed By:   asau
Date:   Fri Feb 19 12:36:15 UTC 2010

Modified Files:
src/sys/dev/i2o: iop.c

Log Message:
Don't mix BUS_DMASYNC_PREREAD and BUS_DMASYNC_POSTWRITE.
Suggested by bouyer, fixes PR kern/42662


To generate a diff of this commit:
cvs rdiff -u -r1.77 -r1.78 src/sys/dev/i2o/iop.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/i2o/iop.c
diff -u src/sys/dev/i2o/iop.c:1.77 src/sys/dev/i2o/iop.c:1.78
--- src/sys/dev/i2o/iop.c:1.77	Wed Oct 21 21:12:05 2009
+++ src/sys/dev/i2o/iop.c	Fri Feb 19 12:36:15 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: iop.c,v 1.77 2009/10/21 21:12:05 rmind Exp $	*/
+/*	$NetBSD: iop.c,v 1.78 2010/02/19 12:36:15 asau Exp $	*/
 
 /*-
  * Copyright (c) 2000, 2001, 2002, 2007 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: iop.c,v 1.77 2009/10/21 21:12:05 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: iop.c,v 1.78 2010/02/19 12:36:15 asau Exp $);
 
 #include iop.h
 
@@ -928,7 +928,7 @@
 	BUS_DMASYNC_PREWRITE);
 	memset(st, 0, sizeof(*st));
 	bus_dmamap_sync(sc-sc_dmat, sc-sc_scr_dmamap, 0, sizeof(*st),
-	BUS_DMASYNC_PREREAD|BUS_DMASYNC_POSTWRITE);
+	BUS_DMASYNC_POSTWRITE);
 
 	if ((rv = iop_post(sc, (u_int32_t *)mf)) != 0)
 		return (rv);
@@ -993,7 +993,7 @@
 	BUS_DMASYNC_PREWRITE);
 	*sw = 0;
 	bus_dmamap_sync(sc-sc_dmat, sc-sc_scr_dmamap, 0, sizeof(*sw),
-	BUS_DMASYNC_PREREAD|BUS_DMASYNC_POSTWRITE);
+	BUS_DMASYNC_POSTWRITE);
 
 	if ((rv = iop_post(sc, mb)) != 0)
 		return (rv);



CVS commit: src/sys/dev/usb

2010-02-19 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Feb 19 12:40:47 UTC 2010

Modified Files:
src/sys/dev/usb: ugen.c

Log Message:
Replace USB_GET_SC() instances with USB_GET_SC_OPEN().  The latter
is exactly like the former, except it returns with ENXIO if sc is
NULL instead of continuing on to use it.  Most of the time this is
handled by the fd layer and you get EBADF, but sometimes it's
possible to race into the device method for whatever reason and
you get a kernel panic.  I have no idea what the whatever reason
might be.


To generate a diff of this commit:
cvs rdiff -u -r1.108 -r1.109 src/sys/dev/usb/ugen.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/usb/ugen.c
diff -u src/sys/dev/usb/ugen.c:1.108 src/sys/dev/usb/ugen.c:1.109
--- src/sys/dev/usb/ugen.c:1.108	Thu Dec 24 01:32:22 2009
+++ src/sys/dev/usb/ugen.c	Fri Feb 19 12:40:47 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: ugen.c,v 1.108 2009/12/24 01:32:22 jakllsch Exp $	*/
+/*	$NetBSD: ugen.c,v 1.109 2010/02/19 12:40:47 pooka Exp $	*/
 
 /*
  * Copyright (c) 1998, 2004 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
 
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: ugen.c,v 1.108 2009/12/24 01:32:22 jakllsch Exp $);
+__KERNEL_RCSID(0, $NetBSD: ugen.c,v 1.109 2010/02/19 12:40:47 pooka Exp $);
 
 #include opt_compat_netbsd.h
 
@@ -507,7 +507,7 @@
 	int dir;
 	int i;
 
-	USB_GET_SC(ugen, UGENUNIT(dev), sc);
+	USB_GET_SC_OPEN(ugen, UGENUNIT(dev), sc);
 
 	DPRINTFN(5, (ugenclose: flag=%d, mode=%d, unit=%d, endpt=%d\n,
 		 flag, mode, UGENUNIT(dev), endpt));
@@ -786,7 +786,7 @@
 	struct ugen_softc *sc;
 	int error;
 
-	USB_GET_SC(ugen, UGENUNIT(dev), sc);
+	USB_GET_SC_OPEN(ugen, UGENUNIT(dev), sc);
 
 	sc-sc_refcnt++;
 	error = ugen_do_read(sc, endpt, uio, flag);
@@ -969,7 +969,7 @@
 	struct ugen_softc *sc;
 	int error;
 
-	USB_GET_SC(ugen, UGENUNIT(dev), sc);
+	USB_GET_SC_OPEN(ugen, UGENUNIT(dev), sc);
 
 	sc-sc_refcnt++;
 	error = ugen_do_write(sc, endpt, uio, flag);
@@ -1823,7 +1823,7 @@
 	struct ugen_softc *sc;
 	int error;
 
-	USB_GET_SC(ugen, UGENUNIT(dev), sc);
+	USB_GET_SC_OPEN(ugen, UGENUNIT(dev), sc);
 
 	sc-sc_refcnt++;
 	error = ugen_do_ioctl(sc, endpt, cmd, addr, flag, l);
@@ -1840,7 +1840,7 @@
 	int revents = 0;
 	int s;
 
-	USB_GET_SC(ugen, UGENUNIT(dev), sc);
+	USB_GET_SC_OPEN(ugen, UGENUNIT(dev), sc);
 
 	if (sc-sc_dying)
 		return (POLLHUP);
@@ -2025,7 +2025,7 @@
 	struct klist *klist;
 	int s;
 
-	USB_GET_SC(ugen, UGENUNIT(dev), sc);
+	USB_GET_SC_OPEN(ugen, UGENUNIT(dev), sc);
 
 	if (sc-sc_dying)
 		return (ENXIO);



CVS commit: src/lib/libterminfo

2010-02-19 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Fri Feb 19 13:53:17 UTC 2010

Modified Files:
src/lib/libterminfo: Makefile

Log Message:
Do clean generated terminfo.5 file.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/lib/libterminfo/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libterminfo/Makefile
diff -u src/lib/libterminfo/Makefile:1.9 src/lib/libterminfo/Makefile:1.10
--- src/lib/libterminfo/Makefile:1.9	Fri Feb 12 12:18:33 2010
+++ src/lib/libterminfo/Makefile	Fri Feb 19 13:53:17 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.9 2010/02/12 12:18:33 roy Exp $
+#	$NetBSD: Makefile,v 1.10 2010/02/19 13:53:17 njoly Exp $
 
 USE_SHLIBDIR=	yes
 
@@ -42,6 +42,8 @@
 		@echo Generating terminfo man pages
 		cd ${.CURDIR}  ${HOST_SH} ./genman ${.OBJDIR}/$@
 
+CLEANFILES+=	terminfo.5
+
 # Allow terminfo descriptions to be compiled into libterminfo
 compiled_terms:
 		@echo Generating compiled terminfo descriptions



CVS commit: src/external/ibm-public/postfix/sbin/postconf

2010-02-19 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Fri Feb 19 13:55:47 UTC 2010

Modified Files:
src/external/ibm-public/postfix/sbin/postconf: Makefile

Log Message:
Add nint_table.h and nint_vars.h to generated list files.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 \
src/external/ibm-public/postfix/sbin/postconf/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/ibm-public/postfix/sbin/postconf/Makefile
diff -u src/external/ibm-public/postfix/sbin/postconf/Makefile:1.1 src/external/ibm-public/postfix/sbin/postconf/Makefile:1.2
--- src/external/ibm-public/postfix/sbin/postconf/Makefile:1.1	Thu Jun 25 18:21:59 2009
+++ src/external/ibm-public/postfix/sbin/postconf/Makefile	Fri Feb 19 13:55:46 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.1 2009/06/25 18:21:59 tron Exp $
+#	$NetBSD: Makefile,v 1.2 2010/02/19 13:55:46 njoly Exp $
 
 # XXX Note we aren't building ../conf/main.cf.default
 # The shipped makefiles construct it using postconf -d after building
@@ -16,8 +16,9 @@
 .PATH:	${DIST}
 
 PSRCS=	postconf.c
-GENSRCS=bool_table.h bool_vars.h int_table.h int_vars.h str_table.h \
-	str_vars.h time_table.h time_vars.h raw_table.h raw_vars.h
+GENSRCS=bool_table.h bool_vars.h int_table.h int_vars.h nint_table.h \
+	nint_vars.h str_table.h str_vars.h time_table.h time_vars.h \
+	raw_table.h raw_vars.h
 AUTOSRCS=auto_table.h auto_vars.h
 
 SRCS=	${PSRCS} ${GENSRCS} ${AUTOSRCS}



CVS commit: src/sys/dev/usb

2010-02-19 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Feb 19 13:55:51 UTC 2010

Modified Files:
src/sys/dev/usb: usbdevs

Log Message:
Add Huawei K3765 (two id's, it changes product id after being inited).


To generate a diff of this commit:
cvs rdiff -u -r1.543 -r1.544 src/sys/dev/usb/usbdevs

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/usb/usbdevs
diff -u src/sys/dev/usb/usbdevs:1.543 src/sys/dev/usb/usbdevs:1.544
--- src/sys/dev/usb/usbdevs:1.543	Mon Feb  8 20:43:00 2010
+++ src/sys/dev/usb/usbdevs	Fri Feb 19 13:55:51 2010
@@ -1,4 +1,4 @@
-$NetBSD: usbdevs,v 1.543 2010/02/08 20:43:00 snj Exp $
+$NetBSD: usbdevs,v 1.544 2010/02/19 13:55:51 pooka Exp $
 
 /*
  * Copyright (c) 1998-2004 The NetBSD Foundation, Inc.
@@ -1262,6 +1262,8 @@
 /* Huawei Technologies products */
 product HUAWEI MOBILE		0x1001	Huawei Mobile
 product HUAWEI E220  		0x1003	Huawei E220
+product HUAWEI K3765  		0x1465	Huawei K3765
+product HUAWEI K3765INIT 	0x1520	Huawei K3765 USB CD
 
 /* Huawei-3Com products */
 product HUAWEI3COM RT2573	0x0009	RT2573



CVS commit: src/external/bsd/flex/dist

2010-02-19 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Fri Feb 19 14:22:43 UTC 2010

Modified Files:
src/external/bsd/flex/dist: initparse.c initscan.c

Log Message:
Regen initparse.c/initscan.c without #line directives, to avoid host
tool depency problems when NETBSDSRCDIR != /usr/src.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/external/bsd/flex/dist/initparse.c
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/flex/dist/initscan.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/flex/dist/initparse.c
diff -u src/external/bsd/flex/dist/initparse.c:1.1 src/external/bsd/flex/dist/initparse.c:1.2
--- src/external/bsd/flex/dist/initparse.c:1.1	Thu Oct 29 17:17:12 2009
+++ src/external/bsd/flex/dist/initparse.c	Fri Feb 19 14:22:43 2010
@@ -12,7 +12,6 @@
 #define YYMAJOR 1
 #define YYMINOR 9
 
-#define YYLEX yylex()
 #define YYEMPTY(-1)
 #define yyclearin  (yychar = YYEMPTY)
 #define yyerrok(yyerrflag = 0)
@@ -21,18 +20,24 @@
 /* compatibility with bison */
 #ifdef YYPARSE_PARAM
 /* compatibility with FreeBSD */
-#ifdef YYPARSE_PARAM_TYPE
-#define YYPARSE_DECL() yyparse(YYPARSE_PARAM_TYPE YYPARSE_PARAM)
+# ifdef YYPARSE_PARAM_TYPE
+#  define YYPARSE_DECL() yyparse(YYPARSE_PARAM_TYPE YYPARSE_PARAM)
+# else
+#  define YYPARSE_DECL() yyparse(void *YYPARSE_PARAM)
+# endif
 #else
-#define YYPARSE_DECL() yyparse(void *YYPARSE_PARAM)
+# define YYPARSE_DECL() yyparse(void)
 #endif
+
+/* Pure parsers. */
+#define YYPURE 0
+#ifdef YYLEX_PARAM
+# define YYLEX yylex(YYLEX_PARAM)
 #else
-#define YYPARSE_DECL() yyparse(void)
-#endif /* YYPARSE_PARAM */
+# define YYLEX yylex()
+#endif
 
-static int yygrowstack(void);
 #define YYPREFIX yy
-#line 37 /usr/src/external/bsd/flex/dist/parse.y
 /*  Copyright (c) 1990 The Regents of the University of California. */
 /*  All rights reserved. */
 
@@ -113,7 +118,6 @@
  */
 #define YYSTYPE int
 
-#line 116 /usr/src/external/bsd/flex/dist/parse.c
 #define CHAR 257
 #define NUMBER 258
 #define SECTEND 259
@@ -465,6 +469,8 @@
 #endif
 
 extern int YYPARSE_DECL();
+static int yygrowstack(short **, short **, short **,
+YYSTYPE **, YYSTYPE **, unsigned *);
 
 /* define the initial stack-sizes */
 #ifdef YYSTACKSIZE
@@ -482,20 +488,11 @@
 #define YYINITSTACKSIZE 500
 
 int  yydebug;
-int  yynerrs;
 int  yyerrflag;
-int  yychar;
-short   *yyssp;
-YYSTYPE *yyvsp;
-YYSTYPE  yyval;
-YYSTYPE  yylval;
-
-/* variables for the parser stack */
-static short   *yyss;
-static short   *yysslim;
-static YYSTYPE *yyvs;
-static unsigned yystacksize;
-#line 952 /usr/src/external/bsd/flex/dist/parse.y
+int  yynerrs;
+int  yychar;
+YYSTYPE  yylval;
+
 
 
 /* build_eof_action - build the EOF action for the active start
@@ -634,41 +631,37 @@
 const char *msg;
 	{
 	}
-#line 637 /usr/src/external/bsd/flex/dist/parse.c
 /* allocate initial stack or double stack size, up to YYMAXDEPTH */
-static int yygrowstack(void)
+static int yygrowstack(short **yyss, short **yyssp, short **yysslim,
+YYSTYPE **yyvs, YYSTYPE **yyvsp, unsigned *yystacksize)
 {
 int i;
 unsigned newsize;
 short *newss;
 YYSTYPE *newvs;
 
-if ((newsize = yystacksize) == 0)
+if ((newsize = *yystacksize) == 0)
 newsize = YYINITSTACKSIZE;
 else if (newsize = YYMAXDEPTH)
 return -1;
 else if ((newsize *= 2)  YYMAXDEPTH)
 newsize = YYMAXDEPTH;
 
-i = yyssp - yyss;
-newss = (yyss != 0)
-  ? (short *)realloc(yyss, newsize * sizeof(*newss))
-  : (short *)malloc(newsize * sizeof(*newss));
+i = *yyssp - *yyss;
+newss = (short *)realloc(*yyss, newsize * sizeof(*newss));
 if (newss == 0)
 return -1;
 
-yyss  = newss;
-yyssp = newss + i;
-newvs = (yyvs != 0)
-  ? (YYSTYPE *)realloc(yyvs, newsize * sizeof(*newvs))
-  : (YYSTYPE *)malloc(newsize * sizeof(*newvs));
+*yyss  = newss;
+*yyssp = newss + i;
+newvs = (YYSTYPE *)realloc(*yyvs, newsize * sizeof(*newvs));
 if (newvs == 0)
 return -1;
 
-yyvs = newvs;
-yyvsp = newvs + i;
-yystacksize = newsize;
-yysslim = yyss + newsize - 1;
+*yyvs = newvs;
+*yyvsp = newvs + i;
+*yystacksize = newsize;
+*yysslim = *yyss + newsize - 1;
 return 0;
 }
 
@@ -681,6 +674,15 @@
 YYPARSE_DECL()
 {
 int yym, yyn, yystate;
+
+YYSTYPE  yyval;
+/* variables for the parser stack */
+short   *yyssp;
+short   *yyss;
+short   *yysslim;
+YYSTYPE *yyvs;
+YYSTYPE *yyvsp;
+unsigned yystacksize;
 #if YYDEBUG
 const char *yys;
 
@@ -697,9 +699,11 @@
 yychar = YYEMPTY;
 yystate = 0;
 
-if (yyss == NULL  yygrowstack()) goto yyoverflow;
-yyssp = yyss;
-yyvsp = yyvs;
+yystacksize = 0;
+yyvs = yyvsp = NULL;
+yyss = yyssp = NULL;
+if (yygrowstack(yyss, yyssp, yysslim, yyvs, yyvsp, yystacksize))
+   

CVS commit: src/sys/dev/usb

2010-02-19 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Feb 19 15:10:02 UTC 2010

Modified Files:
src/sys/dev/usb: u3g.c

Log Message:
Huawei K3765 requires another kind of magic to get it out of CD mode.
It also changes product id after being configured.  Without this
change the device just lingers in u3ginit forever.  With this change:

u3ginit0 at uhub0 port 1: Switching to 3G mode
u3ginit0: detached
u3ginit0: at uhub0 port 1 (addr 2) disconnected
u3g0 at uhub0 port 1 configuration 1 interface 0
ucom0 at u3g0 portno 0: 3G Modem
u3g1 at uhub0 port 1 configuration 1 interface 1
ucom1 at u3g1 portno 1: 3G Modem
u3g2 at uhub0 port 1 configuration 1 interface 2
ucom2 at u3g2 portno 2: 3G Modem
u3g3 at uhub0 port 1 configuration 1 interface 3
ucom3 at u3g3 portno 3: 3G Modem

(tested with rump)


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/sys/dev/usb/u3g.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/usb/u3g.c
diff -u src/sys/dev/usb/u3g.c:1.10 src/sys/dev/usb/u3g.c:1.11
--- src/sys/dev/usb/u3g.c:1.10	Mon Feb  8 20:45:43 2010
+++ src/sys/dev/usb/u3g.c	Fri Feb 19 15:10:02 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: u3g.c,v 1.10 2010/02/08 20:45:43 snj Exp $	*/
+/*	$NetBSD: u3g.c,v 1.11 2010/02/19 15:10:02 pooka Exp $	*/
 
 /*-
  * Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -50,7 +50,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: u3g.c,v 1.10 2010/02/08 20:45:43 snj Exp $);
+__KERNEL_RCSID(0, $NetBSD: u3g.c,v 1.11 2010/02/19 15:10:02 pooka Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -190,6 +190,7 @@
 	/* OEM: Huawei */
 	{ USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_MOBILE },
 	{ USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_E220 },
+	{ USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_K3765 },
 	/* OEM: Novatel */
 	{ USB_VENDOR_NOVATEL2, USB_PRODUCT_NOVATEL2_MERLINV620 },
 	{ USB_VENDOR_NOVATEL2, USB_PRODUCT_NOVATEL2_ES620 },
@@ -240,9 +241,8 @@
 };
 
 static int
-u3g_novatel_reinit(usbd_device_handle dev)
+send_bulkmsg(usbd_device_handle dev, char *cmd, size_t cmdlen)
 {
-	unsigned char cmd[31];
 	usbd_interface_handle iface;
 	usb_interface_descriptor_t *id;
 	usb_endpoint_descriptor_t *ed;
@@ -250,28 +250,6 @@
 	usbd_xfer_handle xfer;
 	int err, i;
 
-	memset(cmd, 0, sizeof(cmd));
-	/* Byte 0..3: Command Block Wrapper (CBW) signature */
-	cmd[0] = 0x55; 
-	cmd[1] = 0x53;
-	cmd[2] = 0x42;
-	cmd[3] = 0x43;
-	/* 4..7: CBW Tag, has to unique, but only a single transfer used. */
-	cmd[4] = 0x01;
-	/* 8..11: CBW Transfer Length, no data here */
-	/* 12: CBW Flag: output, so 0 */
-	/* 13: CBW Lun: 0 */
-	/* 14: CBW Length */
-	cmd[14] = 0x06;
-	/* Rest is the SCSI payload */
-	/* 0: SCSI START/STOP opcode */
-	cmd[15] = 0x1b;
-	/* 1..3 unused */
-	/* 4 Load/Eject command */
-	cmd[19] = 0x02;
-	/* 5: unused */
-
-
 	/* Move the device into the configured state. */
 	err = usbd_set_config_index(dev, 0, 0);
 	if (err) {
@@ -281,7 +259,7 @@
 
 	err = usbd_device2interface_handle(dev, 0, iface);
 	if (err != 0) {
-		aprint_error(u3g: failed to get interface\n);
+		aprint_error(u3ginit: failed to get interface\n);
 		return UMATCH_NONE;
 	}
 
@@ -300,25 +278,30 @@
 	if (i == id-bNumEndpoints)
 		return UMATCH_NONE;
 
-	err = usbd_open_pipe(iface, ed-bEndpointAddress, USBD_EXCLUSIVE_USE,
-	pipe);
+	err = usbd_open_pipe(iface, ed-bEndpointAddress,
+	USBD_EXCLUSIVE_USE, pipe);
 	if (err != 0) {
-		aprint_error(u3g: failed to open bulk transfer pipe %d\n,
+		aprint_error(u3ginit: failed to open bulk transfer pipe %d\n,
 		ed-bEndpointAddress);
 		return UMATCH_NONE;
 	}
 
 	xfer = usbd_alloc_xfer(dev);
 	if (xfer != NULL) {
-		usbd_setup_xfer(xfer, pipe, NULL, cmd, sizeof(cmd),
+		usbd_setup_xfer(xfer, pipe, NULL, cmd, cmdlen,
 		USBD_SYNCHRONOUS, USBD_DEFAULT_TIMEOUT, NULL);
 
 		err = usbd_transfer(xfer);
+
+#if 0 /* XXXpooka: at least my huawei fails this always, but still detaches */
 		if (err)
-			aprint_error(u3g: transfer failed\n);
+			aprint_error(u3ginit: transfer failed\n);
+#else
+		err = 0;
+#endif
 		usbd_free_xfer(xfer);
 	} else {
-		aprint_error(u3g: failed to allocate xfer\n);
+		aprint_error(u3ginit: failed to allocate xfer\n);
 		err = USBD_NOMEM;
 	}
 
@@ -329,6 +312,35 @@
 }
 
 static int
+u3g_novatel_reinit(usbd_device_handle dev)
+{
+	unsigned char cmd[31];
+
+	memset(cmd, 0, sizeof(cmd));
+	/* Byte 0..3: Command Block Wrapper (CBW) signature */
+	cmd[0] = 0x55; 
+	cmd[1] = 0x53;
+	cmd[2] = 0x42;
+	cmd[3] = 0x43;
+	/* 4..7: CBW Tag, has to unique, but only a single transfer used. */
+	cmd[4] = 0x01;
+	/* 8..11: CBW Transfer Length, no data here */
+	/* 12: CBW Flag: output, so 0 */
+	/* 13: CBW Lun: 0 */
+	/* 14: CBW Length */
+	cmd[14] = 0x06;
+	/* Rest is the SCSI payload */
+	/* 0: SCSI START/STOP opcode */
+	cmd[15] = 0x1b;
+	/* 1..3 unused */
+	/* 4 Load/Eject command */
+	cmd[19] = 0x02;
+	/* 5: unused */
+
+	return send_bulkmsg(dev, cmd, 

CVS commit: src/sys/arch/algor/conf

2010-02-19 Thread Havard Eidnes
Module Name:src
Committed By:   he
Date:   Fri Feb 19 15:25:28 UTC 2010

Modified Files:
src/sys/arch/algor/conf: P5064

Log Message:
Bump SYMTAB_SPACE so that it fits again.


To generate a diff of this commit:
cvs rdiff -u -r1.57 -r1.58 src/sys/arch/algor/conf/P5064

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/algor/conf/P5064
diff -u src/sys/arch/algor/conf/P5064:1.57 src/sys/arch/algor/conf/P5064:1.58
--- src/sys/arch/algor/conf/P5064:1.57	Fri Mar  6 20:31:46 2009
+++ src/sys/arch/algor/conf/P5064	Fri Feb 19 15:25:28 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: P5064,v 1.57 2009/03/06 20:31:46 joerg Exp $
+#	$NetBSD: P5064,v 1.58 2010/02/19 15:25:28 he Exp $
 #
 # Algorithmics P-5064 kernel.
 #
@@ -7,7 +7,7 @@
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		P5064-$Revision: 1.57 $
+#ident 		P5064-$Revision: 1.58 $
 
 maxusers 32
 
@@ -25,7 +25,7 @@
 options 	DDB			# kernel debugger
 makeoptions	DEBUG=-g
 #makeoptions	DEBUGLIST=pattern1 pattern2 ...
-options 	SYMTAB_SPACE=39
+options 	SYMTAB_SPACE=40
 
 # File systems
 file-system	FFS		# Fast file system



CVS commit: src/usr.bin/sed

2010-02-19 Thread Tobias Nygren
Module Name:src
Committed By:   tnn
Date:   Fri Feb 19 16:35:27 UTC 2010

Modified Files:
src/usr.bin/sed: compile.c defs.h extern.h main.c misc.c

Log Message:
Merge the following revisions from OpenBSD to let sed(1) handle
arbitrarily long lines (closes our PR bin/42261).
openbsd/usr.bin/sed/extern.h 1.5
openbsd/usr.bin/sed/main.c 1.13-1.15
openbsd/usr.bin/sed/misc.c 1.8
openbsd/usr.bin/sed/compile.c 1.25-1.28
openbsd/usr.bin/sed/defs.h 1.4


To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/usr.bin/sed/compile.c
cvs rdiff -u -r1.9 -r1.10 src/usr.bin/sed/defs.h
cvs rdiff -u -r1.10 -r1.11 src/usr.bin/sed/extern.h src/usr.bin/sed/misc.c
cvs rdiff -u -r1.20 -r1.21 src/usr.bin/sed/main.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/sed/compile.c
diff -u src/usr.bin/sed/compile.c:1.36 src/usr.bin/sed/compile.c:1.37
--- src/usr.bin/sed/compile.c:1.36	Mon Apr 13 07:29:55 2009
+++ src/usr.bin/sed/compile.c	Fri Feb 19 16:35:27 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: compile.c,v 1.36 2009/04/13 07:29:55 lukem Exp $	*/
+/*	$NetBSD: compile.c,v 1.37 2010/02/19 16:35:27 tnn Exp $	*/
 
 /*-
  * Copyright (c) 1992, 1993
@@ -76,7 +76,7 @@
 #if 0
 static char sccsid[] = @(#)compile.c	8.2 (Berkeley) 4/28/95;
 #else
-__RCSID($NetBSD: compile.c,v 1.36 2009/04/13 07:29:55 lukem Exp $);
+__RCSID($NetBSD: compile.c,v 1.37 2010/02/19 16:35:27 tnn Exp $);
 #endif
 #endif /* not lint */
 
@@ -193,14 +193,15 @@
 compile_stream(struct s_command **link)
 {
 	char *p;
-	static char lbuf[_POSIX2_LINE_MAX + 1];	/* To save stack */
+	static char *lbuf;	/* To avoid excessive malloc calls */
+	static size_t bufsize;
 	struct s_command *cmd, *cmd2, *stack;
 	struct s_format *fp;
 	int naddr;/* Number of addresses */
 
 	stack = 0;
 	for (;;) {
-		if ((p = cu_fgets(lbuf, sizeof(lbuf))) == NULL) {
+		if ((p = cu_fgets(lbuf, bufsize)) == NULL) {
 			if (stack != 0)
 err(COMPILE, unexpected EOF (pending }'s));
 			return (link);
@@ -459,11 +460,13 @@
 compile_re(char *p, regex_t **repp)
 {
 	int eval;
-	char re[_POSIX2_LINE_MAX + 1];
+	char *re;
 
+	re = xmalloc(strlen(p) + 1); /* strlen(re) = strlen(p) */
 	p = compile_delimited(p, re);
 	if (p  strlen(re) == 0) {
 		*repp = NULL;
+		free(re);
 		return (p);
 	}
 	*repp = xmalloc(sizeof(regex_t));
@@ -482,8 +485,9 @@
 static char *
 compile_subst(char *p, struct s_subst *s)
 {
-	static char lbuf[_POSIX2_LINE_MAX + 1];
-	int asize, ref, size;
+	static char *lbuf;
+	static size_t bufsize;
+	int asize, ref, size, len;
 	char c, *text, *op, *sp;
 	int sawesc = 0;
 
@@ -493,10 +497,16 @@
 
 	s-maxbref = 0;
 	s-linenum = linenum;
-	asize = 2 * _POSIX2_LINE_MAX + 1;
-	text = xmalloc(asize);
-	size = 0;
+	text = NULL;
+	asize = size = 0;
 	do {
+		len = ROUNDLEN(strlen(p) + 1);
+		if (asize - size  len) {
+			do {
+asize += len;
+			} while (asize - size  len);
+			text = xrealloc(text, asize);
+		}
 		op = sp = text + size;
 		for (; *p; p++) {
 			if (*p == '\\' || sawesc) {
@@ -546,11 +556,7 @@
 			*sp++ = *p;
 		}
 		size += sp - op;
-		if (asize - size  _POSIX2_LINE_MAX + 1) {
-			asize *= 2;
-			text = xrealloc(text, asize);
-		}
-	} while (cu_fgets(p = lbuf, sizeof(lbuf)));
+	} while ((p = cu_fgets(lbuf, bufsize)));
 	err(COMPILE, unterminated substitute in regular expression);
 	/* NOTREACHED */
 	return (NULL);
@@ -563,7 +569,7 @@
 compile_flags(char *p, struct s_subst *s)
 {
 	int gn;			/* True if we have seen g or n */
-	char wfile[_POSIX2_LINE_MAX + 1], *q;
+	char wfile[PATH_MAX], *q;
 
 	s-n = 1;/* Default */
 	s-p = 0;
@@ -638,26 +644,27 @@
 {
 	int i;
 	char *lt, *op, *np;
-	char old[_POSIX2_LINE_MAX + 1];
-	char new[_POSIX2_LINE_MAX + 1];
+	char *old = NULL, *new = NULL;
 
 	if (*p == '\0' || *p == '\\')
 		err(COMPILE,
 transform pattern can not be delimited by newline or backslash);
+	old = xmalloc(strlen(p) + 1);
 	p = compile_delimited(p, old);
 	if (p == NULL) {
 		err(COMPILE, unterminated transform source string);
-		return (NULL);
+		goto bad;
 	}
+	new = xmalloc(strlen(p) + 1);
 	p = compile_delimited(--p, new);
 	if (p == NULL) {
 		err(COMPILE, unterminated transform target string);
-		return (NULL);
+		goto bad;
 	}
 	EATSPACE();
 	if (strlen(new) != strlen(old)) {
 		err(COMPILE, transform strings are not the same length);
-		return (NULL);
+		goto bad;
 	}
 	/* We assume characters are 8 bits */
 	lt = xmalloc(UCHAR_MAX+1);
@@ -666,7 +673,13 @@
 	for (op = old, np = new; *op; op++, np++)
 		lt[(u_char)*op] = *np;
 	*transtab = lt;
+	free(old);
+	free(new);
 	return (p);
+bad:
+	free(old);
+	free(new);
+	return (NULL);
 }
 
 /*
@@ -675,16 +688,21 @@
 static char *
 compile_text(void)
 {
-	int asize, size;
-	char *text, *p, *op, *s;
-	char lbuf[_POSIX2_LINE_MAX + 1];
-
-	asize = 2 * _POSIX2_LINE_MAX + 1;
-	text = xmalloc(asize);
-	size = 0;
-	while (cu_fgets(lbuf, sizeof(lbuf))) {
+	int asize, size, len;
+	char *lbuf, *text, 

CVS commit: src/lib/libss

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Fri Feb 19 17:48:59 UTC 2010

Modified Files:
src/lib/libss: Makefile

Log Message:
libss uses strupr from libroken, so depend on that.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/lib/libss/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libss/Makefile
diff -u src/lib/libss/Makefile:1.8 src/lib/libss/Makefile:1.9
--- src/lib/libss/Makefile:1.8	Wed Feb  3 15:34:43 2010
+++ src/lib/libss/Makefile	Fri Feb 19 17:48:59 2010
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.8 2010/02/03 15:34:43 roy Exp $
+# $NetBSD: Makefile,v 1.9 2010/02/19 17:48:59 joerg Exp $
 
 USE_FORT?= yes	# network protocol library
 
@@ -15,7 +15,8 @@
 
 LIBDPLIBS+=	edit ${.CURDIR}/../libedit \
 		terminfo ${.CURDIR}/../libterminfo \
-		com_err	${.CURDIR}/../libcom_err
+		com_err	${.CURDIR}/../libcom_err \
+		roken ${.CURDIR}/../libroken
 
 SRCS=		sl.c ss.c
 INCS=		ss.h



CVS commit: src/lib/libroken

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Fri Feb 19 17:57:06 UTC 2010

Modified Files:
src/lib/libroken: Makefile

Log Message:
Link libroken against libcrypt for crypt(3).


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/lib/libroken/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libroken/Makefile
diff -u src/lib/libroken/Makefile:1.17 src/lib/libroken/Makefile:1.18
--- src/lib/libroken/Makefile:1.17	Sun Jul 20 16:25:35 2008
+++ src/lib/libroken/Makefile	Fri Feb 19 17:57:06 2010
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.17 2008/07/20 16:25:35 veego Exp $
+# $NetBSD: Makefile,v 1.18 2010/02/19 17:57:06 joerg Exp $
 
 NOLINT=		# defined
 
@@ -12,7 +12,8 @@
 LIB=		roken
 
 .if ${OBJECT_FMT} == ELF
-LIBDPLIBS+= util ${.CURDIR}/../libutil
+LIBDPLIBS+=	util ${.CURDIR}/../libutil \
+		crypt ${.CURDIR}/../libcrypt
 .else
 .PATH: ${NETBSDSRCDIR}/lib/libutil
 SRCS+=	efun.c



CVS commit: src/lib/libcurses

2010-02-19 Thread Matthias Drochner
Module Name:src
Committed By:   drochner
Date:   Fri Feb 19 19:09:15 UTC 2010

Modified Files:
src/lib/libcurses: curses_line.3

Log Message:
explain a non-portable behavior


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/lib/libcurses/curses_line.3

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libcurses/curses_line.3
diff -u src/lib/libcurses/curses_line.3:1.4 src/lib/libcurses/curses_line.3:1.5
--- src/lib/libcurses/curses_line.3:1.4	Wed Apr 16 13:35:01 2003
+++ src/lib/libcurses/curses_line.3	Fri Feb 19 19:09:15 2010
@@ -1,4 +1,4 @@
-.\	$NetBSD: curses_line.3,v 1.4 2003/04/16 13:35:01 wiz Exp $
+.\	$NetBSD: curses_line.3,v 1.5 2010/02/19 19:09:15 drochner Exp $
 .\
 .\ Copyright (c) 2002
 .\	Brett Lymn (bl...@netbsd.org, brett_l...@yahoo.com.au)
@@ -154,6 +154,18 @@
 .Nx
 Curses library complies with the X/Open Curses specification, part of
 the Single Unix Specification.
+.Pp
+The use of
+.Dv ACS_HLINE
+and
+.Dv ACS_VLINE
+as default drawing character in
+.Fn hline
+and
+.Fn vline
+is a
+.Nx
+extension which should not be relied on in portable code.
 .Sh HISTORY
 The Curses package appeared in
 .Bx 4.0 .



CVS commit: src/sys/kern

2010-02-19 Thread David Young
Module Name:src
Committed By:   dyoung
Date:   Fri Feb 19 22:28:47 UTC 2010

Modified Files:
src/sys/kern: subr_autoconf.c

Log Message:
Avoid a potential crash:  get more struct device initialization
out of the way before trying to get a unit number.  If we cannot
get a unit number, we call config_devfree(), which expects for
fields such as dv_flags, dv_cfattach, and dv_private to be initialized.


To generate a diff of this commit:
cvs rdiff -u -r1.201 -r1.202 src/sys/kern/subr_autoconf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/kern/subr_autoconf.c
diff -u src/sys/kern/subr_autoconf.c:1.201 src/sys/kern/subr_autoconf.c:1.202
--- src/sys/kern/subr_autoconf.c:1.201	Mon Feb 15 20:20:34 2010
+++ src/sys/kern/subr_autoconf.c	Fri Feb 19 22:28:47 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: subr_autoconf.c,v 1.201 2010/02/15 20:20:34 dyoung Exp $ */
+/* $NetBSD: subr_autoconf.c,v 1.202 2010/02/19 22:28:47 dyoung Exp $ */
 
 /*
  * Copyright (c) 1996, 2000 Christopher G. Demetriou
@@ -77,7 +77,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: subr_autoconf.c,v 1.201 2010/02/15 20:20:34 dyoung Exp $);
+__KERNEL_RCSID(0, $NetBSD: subr_autoconf.c,v 1.202 2010/02/19 22:28:47 dyoung Exp $);
 
 #ifdef _KERNEL_OPT
 #include opt_ddb.h
@@ -1184,6 +1184,15 @@
 	if (dev == NULL)
 		panic(config_devalloc: memory allocation for device_t failed);
 
+	dev-dv_class = cd-cd_class;
+	dev-dv_cfdata = cf;
+	dev-dv_cfdriver = cd;
+	dev-dv_cfattach = ca;
+	dev-dv_activity_count = 0;
+	dev-dv_activity_handlers = NULL;
+	dev-dv_private = dev_private;
+	dev-dv_flags = ca-ca_flags;	/* inherit flags from class */
+
 	myunit = config_unit_alloc(dev, cd, cf);
 	if (myunit == -1) {
 		config_devfree(dev);
@@ -1202,13 +1211,6 @@
 	mutex_init(dvl-dvl_mtx, MUTEX_DEFAULT, IPL_NONE);
 	cv_init(dvl-dvl_cv, pmfsusp);
 
-	dev-dv_class = cd-cd_class;
-	dev-dv_cfdata = cf;
-	dev-dv_cfdriver = cd;
-	dev-dv_cfattach = ca;
-	dev-dv_activity_count = 0;
-	dev-dv_activity_handlers = NULL;
-	dev-dv_private = dev_private;
 	memcpy(dev-dv_xname, cd-cd_name, lname);
 	memcpy(dev-dv_xname + lname, xunit, lunit);
 	dev-dv_parent = parent;
@@ -1216,8 +1218,7 @@
 		dev-dv_depth = parent-dv_depth + 1;
 	else
 		dev-dv_depth = 0;
-	dev-dv_flags = DVF_ACTIVE;	/* always initially active */
-	dev-dv_flags |= ca-ca_flags;	/* inherit flags from class */
+	dev-dv_flags |= DVF_ACTIVE;	/* always initially active */
 	if (locs) {
 		KASSERT(parent); /* no locators at root */
 		ia = cfiattr_lookup(cfdata_ifattr(cf), parent-dv_cfdriver);



CVS commit: src/external/bsd/mdocml/dist

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Fri Feb 19 22:55:13 UTC 2010

Update of /cvsroot/src/external/bsd/mdocml/dist
In directory ivanova.netbsd.org:/tmp/cvs-serv8978

Log Message:
Import mdocml 1.9.15 modulo a patch for .Xr handling:
- XHTML output support, more human-readable HTML output
- end-of-line white space detected in all lines
- fix subtle bug for list displays in some modes
- fix column handling
- full support for \f etc
- imporoved column handling
- various other bug fixes
- compatiblity support for strlcat/strlcpy
- groff-compatible .Xr [backed out]

Status:

Vendor Tag: KRISTAPS
Release Tags:   mdocml-1-9-15

U src/external/bsd/mdocml/dist/mdoc_macro.c
N src/external/bsd/mdocml/dist/config.h.pre
N src/external/bsd/mdocml/dist/test-strlcpy.c
N src/external/bsd/mdocml/dist/test-strlcat.c
U src/external/bsd/mdocml/dist/external.png.uu
U src/external/bsd/mdocml/dist/chars.in
U src/external/bsd/mdocml/dist/vol.in
U src/external/bsd/mdocml/dist/st.in
U src/external/bsd/mdocml/dist/msec.in
U src/external/bsd/mdocml/dist/lib.in
U src/external/bsd/mdocml/dist/att.in
U src/external/bsd/mdocml/dist/arch.in
U src/external/bsd/mdocml/dist/style.css
U src/external/bsd/mdocml/dist/man.3
U src/external/bsd/mdocml/dist/man.7
U src/external/bsd/mdocml/dist/mandoc_char.7
U src/external/bsd/mdocml/dist/manuals.7
U src/external/bsd/mdocml/dist/mdoc.7
U src/external/bsd/mdocml/dist/mdoc.3
U src/external/bsd/mdocml/dist/mandoc.1
N src/external/bsd/mdocml/dist/Makefile
U src/external/bsd/mdocml/dist/main.h
U src/external/bsd/mdocml/dist/out.h
U src/external/bsd/mdocml/dist/chars.h
U src/external/bsd/mdocml/dist/html.h
U src/external/bsd/mdocml/dist/libmandoc.h
U src/external/bsd/mdocml/dist/term.h
U src/external/bsd/mdocml/dist/libman.h
U src/external/bsd/mdocml/dist/man.h
U src/external/bsd/mdocml/dist/libmdoc.h
U src/external/bsd/mdocml/dist/mdoc.h
U src/external/bsd/mdocml/dist/man_argv.c
U src/external/bsd/mdocml/dist/mandoc.c
U src/external/bsd/mdocml/dist/man_action.c
U src/external/bsd/mdocml/dist/man_validate.c
U src/external/bsd/mdocml/dist/man_hash.c
U src/external/bsd/mdocml/dist/man.c
U src/external/bsd/mdocml/dist/man_macro.c
U src/external/bsd/mdocml/dist/out.c
U src/external/bsd/mdocml/dist/man_html.c
U src/external/bsd/mdocml/dist/mdoc_html.c
U src/external/bsd/mdocml/dist/html.c
U src/external/bsd/mdocml/dist/man_term.c
U src/external/bsd/mdocml/dist/compat.c
U src/external/bsd/mdocml/dist/tree.c
U src/external/bsd/mdocml/dist/term.c
U src/external/bsd/mdocml/dist/chars.c
U src/external/bsd/mdocml/dist/main.c
U src/external/bsd/mdocml/dist/mdoc_term.c
U src/external/bsd/mdocml/dist/st.c
U src/external/bsd/mdocml/dist/msec.c
U src/external/bsd/mdocml/dist/vol.c
U src/external/bsd/mdocml/dist/arch.c
U src/external/bsd/mdocml/dist/att.c
U src/external/bsd/mdocml/dist/lib.c
C src/external/bsd/mdocml/dist/mdoc_action.c
U src/external/bsd/mdocml/dist/mdoc_validate.c
U src/external/bsd/mdocml/dist/mdoc_argv.c
U src/external/bsd/mdocml/dist/mdoc_strings.c
U src/external/bsd/mdocml/dist/mdoc_hash.c
U src/external/bsd/mdocml/dist/mdoc.c
N src/external/bsd/mdocml/dist/config.h.post

1 conflicts created by this import.
Use the following command to help the merge:

cvs checkout -jKRISTAPS:yesterday -jKRISTAPS 
src/external/bsd/mdocml/dist



CVS commit: src/external/bsd/mdocml/dist

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Fri Feb 19 23:01:28 UTC 2010

Modified Files:
src/external/bsd/mdocml/dist: mdoc_action.c

Log Message:
Merge


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/mdocml/dist/mdoc_action.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/mdocml/dist/mdoc_action.c
diff -u src/external/bsd/mdocml/dist/mdoc_action.c:1.4 src/external/bsd/mdocml/dist/mdoc_action.c:1.5
--- src/external/bsd/mdocml/dist/mdoc_action.c:1.4	Thu Nov  5 20:38:42 2009
+++ src/external/bsd/mdocml/dist/mdoc_action.c	Fri Feb 19 23:01:28 2010
@@ -1,4 +1,4 @@
-/*	$Vendor-Id: mdoc_action.c,v 1.49 2009/11/02 06:22:45 kristaps Exp $ */
+/*	$Vendor-Id: mdoc_action.c,v 1.50 2010/01/01 17:14:29 kristaps Exp $ */
 /*
  * Copyright (c) 2008, 2009 Kristaps Dzonsons krist...@kth.se
  *
@@ -14,6 +14,10 @@
  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
+#ifdef HAVE_CONFIG_H
+#include config.h
+#endif
+
 #ifndef	OSNAME
 #include sys/utsname.h
 #endif
@@ -42,10 +46,6 @@
 			const struct mdoc_node *, size_t);
 static	inline int order_rs(int);
 
-#ifdef __linux__
-extern	size_t	  strlcat(char *, const char *, size_t);
-#endif
-
 static	int	  post_ar(POST_ARGS);
 static	int	  post_at(POST_ARGS);
 static	int	  post_bl(POST_ARGS);



CVS commit: src/external/bsd/mdocml

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Fri Feb 19 23:02:41 UTC 2010

Modified Files:
src/external/bsd/mdocml: Makefile.inc prepare-import.sh

Log Message:
Update build system for mdocml 1.9.15.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/mdocml/Makefile.inc
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/mdocml/prepare-import.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/mdocml/Makefile.inc
diff -u src/external/bsd/mdocml/Makefile.inc:1.4 src/external/bsd/mdocml/Makefile.inc:1.5
--- src/external/bsd/mdocml/Makefile.inc:1.4	Mon Nov 16 22:28:43 2009
+++ src/external/bsd/mdocml/Makefile.inc	Fri Feb 19 23:02:41 2010
@@ -1,11 +1,16 @@
-# $NetBSD: Makefile.inc,v 1.4 2009/11/16 22:28:43 joerg Exp $
+# $NetBSD: Makefile.inc,v 1.5 2010/02/19 23:02:41 joerg Exp $
 
 .include bsd.own.mk
 
-VERSION=	1.9.14
+VERSION=	1.9.15pl1
 
 CPPFLAGS+=	-DVERSION=\${VERSION}\
 
+.if (${HOSTPROG:U} == )
+CPPFLAGE+=	-DHAVE_STRLCAT -DHAVE_STRLCPY
+.endif
+
+
 DISTDIR:=	${.PARSEDIR}/dist
 
 .PATH:	${DISTDIR}

Index: src/external/bsd/mdocml/prepare-import.sh
diff -u src/external/bsd/mdocml/prepare-import.sh:1.2 src/external/bsd/mdocml/prepare-import.sh:1.3
--- src/external/bsd/mdocml/prepare-import.sh:1.2	Mon Oct 26 14:50:45 2009
+++ src/external/bsd/mdocml/prepare-import.sh	Fri Feb 19 23:02:41 2010
@@ -3,7 +3,7 @@
 set -e
 
 cd dist
-rm -rf ChangeLog.xsl Makefile example.style.css index.css *.sgml
+rm -rf ChangeLog.xsl example.style.css index.css *.sgml
 
 uuencode external.png  external.png  external.png.uu
 rm external.png



CVS commit: src/tools/mandoc

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Fri Feb 19 23:03:02 UTC 2010

Modified Files:
src/tools/mandoc: Makefile

Log Message:
Update tool version for mdocml 1.9.15.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tools/mandoc/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/tools/mandoc/Makefile
diff -u src/tools/mandoc/Makefile:1.3 src/tools/mandoc/Makefile:1.4
--- src/tools/mandoc/Makefile:1.3	Fri Oct 30 17:18:51 2009
+++ src/tools/mandoc/Makefile	Fri Feb 19 23:03:02 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.3 2009/10/30 17:18:51 joerg Exp $
+#	$NetBSD: Makefile,v 1.4 2010/02/19 23:03:02 joerg Exp $
 
 HOSTPROGNAME=	${_TOOL_PREFIX}mandoc
 HOST_SRCDIR=	external/bsd/mdocml/bin/mandoc
@@ -10,6 +10,24 @@
 NETBSD_MINOR!=	${HOST_SH} ${NETBSDSRCDIR}/sys/conf/osrelease.sh -n
 NETBSD_OSNAME=	NetBSD ${NETBSD_MINOR}
 
-HOST_CPPFLAGS+=	-DOSNAME=${NETBSD_OSNAME:Q}
+HOST_CPPFLAGS+=	-DOSNAME=${NETBSD_OSNAME:Q} -DHAVE_CONFIG_H -I.
+
+DPSRCS+=	config.h
+
+config.h: config.h.pre config.h.post
+	rm -f config.log
+	( cat ${DISTDIR}/config.h.pre; \
+	echo; \
+	if $(CC) $(CFLAGS) -Werror -c ${DISTDIR}/test-strlcat.c  config.log 21; then \
+		echo '#define HAVE_STRLCAT'; \
+		rm test-strlcat.o; \
+	fi; \
+	if $(CC) $(CFLAGS) -Werror -c ${DISTDIR}/test-strlcpy.c  config.log 21; then \
+		echo '#define HAVE_STRLCPY'; \
+		rm test-strlcpy.o; \
+	fi; \
+	echo; \
+	cat ${DISTDIR}/config.h.post \
+	)  $@
 
 .include ${.CURDIR}/../Makefile.host



CVS commit: src/external/gpl2/xcvs/dist/src

2010-02-19 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb 19 23:50:55 UTC 2010

Modified Files:
src/external/gpl2/xcvs/dist/src: logmsg.c

Log Message:
make the default action abort for the empty log message; it used to be
continue. requested by joerg.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/gpl2/xcvs/dist/src/logmsg.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl2/xcvs/dist/src/logmsg.c
diff -u src/external/gpl2/xcvs/dist/src/logmsg.c:1.2 src/external/gpl2/xcvs/dist/src/logmsg.c:1.3
--- src/external/gpl2/xcvs/dist/src/logmsg.c:1.2	Wed Apr  8 12:27:51 2009
+++ src/external/gpl2/xcvs/dist/src/logmsg.c	Fri Feb 19 18:50:55 2010
@@ -357,7 +357,7 @@
 	{
 	(void) printf (\nLog message unchanged or not specified\n);
 	(void) printf (a)bort, c)ontinue, e)dit, !)reuse this message unchanged for remaining dirs\n);
-	(void) printf (Action: (continue) );
+	(void) printf (Action: (abort) );
 	(void) fflush (stdout);
 	line_length = getline (line, line_chars_allocated, stdin);
 	if (line_length  0)
@@ -369,14 +369,14 @@
 		error (1, 0, aborting);
 	}
 	else if (line_length == 0
-		 || *line == '\n' || *line == 'c' || *line == 'C')
-		break;
-	if (*line == 'a' || *line == 'A')
+		 || *line == '\n' || *line == 'a' || *line == 'A')
 		{
 		if (unlink_file (fname)  0)
 			error (0, errno, warning: cannot remove temp file %s, fname);
 		error (1, 0, aborted by user);
 		}
+	if (*line == 'c' || *line == 'C')
+		break;
 	if (*line == 'e' || *line == 'E')
 		goto again;
 	if (*line == '!')



CVS commit: src/tools

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Sat Feb 20 00:35:12 UTC 2010

Modified Files:
src/tools: Makefile

Log Message:
Build mandoc unconditional if man pages are desirable.  All
compatibility issues are supposed to be sorted out.
Build groff conditionally on MKGROFF. It is currently the only component
that requires C++.


To generate a diff of this commit:
cvs rdiff -u -r1.135 -r1.136 src/tools/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/tools/Makefile
diff -u src/tools/Makefile:1.135 src/tools/Makefile:1.136
--- src/tools/Makefile:1.135	Wed Feb  3 20:56:54 2010
+++ src/tools/Makefile	Sat Feb 20 00:35:11 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.135 2010/02/03 20:56:54 roy Exp $
+#	$NetBSD: Makefile,v 1.136 2010/02/20 00:35:11 joerg Exp $
 
 .include bsd.own.mk
 
@@ -55,10 +55,10 @@
 		pwd_mkdb stat strfile sunlabel zic
 
 .if ${MKMAN} != no || ${MKDOC} != no || ${MKHTML} != no
+.  if ${MKGROFF} != no
 SUBDIR+=	groff
-.  if ${MKMANDOC} == yes
-SUBDIR+=	mandoc
 .  endif
+SUBDIR+=	mandoc
 .endif
 
 .if ${MKMAINTAINERTOOLS:Uno} != no



CVS commit: src/external/bsd/libarchive/dist

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Sat Feb 20 02:49:21 UTC 2010

Update of /cvsroot/src/external/bsd/libarchive/dist
In directory ivanova.netbsd.org:/tmp/cvs-serv21324

Log Message:
Import libarchive 2.8.0:
- Infrastructure:
  - Allow command line tools as fallback for missing compression
libraries. If compiled without gzip for example, gunzip will
be used automatically.
  - Improved support for a number of platforms like high-resolution
timestamps and Extended Attributes on various Unix systems
  - New convience interface for creating archives based on disk content,
complement of the archive_write_disk interface.
- Frontends:
  - bsdcpio ready for public consumption
  - hand-written date parser replaces the yacc code
- Filter system:
  - Simplified read filter chains
  - Option support for filters
  - LZMA, XZ, uudecode handled
- Format support:
  - Write support for mtree files based on file system or archive
content
  - Basic read support for Joliet
  - Write support for zip files
  - Write support for shar archives, both text-only and binary-safe

Status:

Vendor Tag: KIENTZLE
Release Tags:   libarchive-2-8-0

N src/external/bsd/libarchive/dist/README
U src/external/bsd/libarchive/dist/COPYING
U src/external/bsd/libarchive/dist/NEWS
U src/external/bsd/libarchive/dist/cpio/cmdline.c
U src/external/bsd/libarchive/dist/cpio/cpio.c
U src/external/bsd/libarchive/dist/cpio/cpio.h
U src/external/bsd/libarchive/dist/cpio/cpio_platform.h
N src/external/bsd/libarchive/dist/cpio/cpio_windows.h
N src/external/bsd/libarchive/dist/cpio/cpio_windows.c
U src/external/bsd/libarchive/dist/cpio/bsdcpio.1
U src/external/bsd/libarchive/dist/cpio/test/main.c
U src/external/bsd/libarchive/dist/cpio/test/test.h
U src/external/bsd/libarchive/dist/cpio/test/test_0.c
U src/external/bsd/libarchive/dist/cpio/test/test_basic.c
N src/external/bsd/libarchive/dist/cpio/test/test_cmdline.c
U src/external/bsd/libarchive/dist/cpio/test/test_format_newc.c
U src/external/bsd/libarchive/dist/cpio/test/test_gcpio_compat.c
N src/external/bsd/libarchive/dist/cpio/test/test_option_B_upper.c
N src/external/bsd/libarchive/dist/cpio/test/test_option_C_upper.c
N src/external/bsd/libarchive/dist/cpio/test/test_option_J_upper.c
N src/external/bsd/libarchive/dist/cpio/test/test_option_L_upper.c
N src/external/bsd/libarchive/dist/cpio/test/test_option_Z_upper.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_a.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_c.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_d.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_f.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_help.c
N src/external/bsd/libarchive/dist/cpio/test/test_option_l.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_m.c
N src/external/bsd/libarchive/dist/cpio/test/test_option_lzma.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_t.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_u.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_version.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_y.c
U src/external/bsd/libarchive/dist/cpio/test/test_option_z.c
U src/external/bsd/libarchive/dist/cpio/test/test_owner_parse.c
N src/external/bsd/libarchive/dist/cpio/test/test_passthrough_dotdot.c
N src/external/bsd/libarchive/dist/cpio/test/test_passthrough_reverse.c
U src/external/bsd/libarchive/dist/cpio/test/test_pathmatch.c
U src/external/bsd/libarchive/dist/cpio/test/list.h
U src/external/bsd/libarchive/dist/cpio/test/test_gcpio_compat_ref.bin.uu
U src/external/bsd/libarchive/dist/cpio/test/test_gcpio_compat_ref.crc.uu
U src/external/bsd/libarchive/dist/cpio/test/test_gcpio_compat_ref.newc.uu
U src/external/bsd/libarchive/dist/cpio/test/test_gcpio_compat_ref.ustar.uu
N src/external/bsd/libarchive/dist/cpio/test/CMakeLists.txt
U src/external/bsd/libarchive/dist/cpio/test/test_option_f.cpio.uu
U src/external/bsd/libarchive/dist/cpio/test/test_option_m.cpio.uu
U src/external/bsd/libarchive/dist/cpio/test/test_option_t.cpio.uu
U src/external/bsd/libarchive/dist/cpio/test/test_option_t.stdout.uu
U src/external/bsd/libarchive/dist/cpio/test/test_option_tv.stdout.uu
U src/external/bsd/libarchive/dist/libarchive/archive.h
U src/external/bsd/libarchive/dist/libarchive/archive_entry.h
U src/external/bsd/libarchive/dist/libarchive/archive_check_magic.c
U src/external/bsd/libarchive/dist/libarchive/archive_endian.h
U src/external/bsd/libarchive/dist/libarchive/archive_entry.c
U src/external/bsd/libarchive/dist/libarchive/archive_entry_copy_stat.c
U src/external/bsd/libarchive/dist/libarchive/archive_entry_link_resolver.c
U src/external/bsd/libarchive/dist/libarchive/archive_entry_private.h
U src/external/bsd/libarchive/dist/libarchive/archive_entry_stat.c
U src/external/bsd/libarchive/dist/libarchive/archive_entry_strmode.c
N src/external/bsd/libarchive/dist/libarchive/archive_entry_xattr.c
N 

CVS commit: src/external/bsd/libarchive/dist

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Sat Feb 20 02:51:33 UTC 2010

Modified Files:
src/external/bsd/libarchive/dist/libarchive: archive_read.3
archive_read_disk.3 archive_write.3 archive_write_disk.3
Removed Files:
src/external/bsd/libarchive/dist/cpio: err.c matching.c matching.h
pathmatch.c pathmatch.h
src/external/bsd/libarchive/dist/cpio/test: test_option_B.c
test_option_L.c test_option_ell.c
src/external/bsd/libarchive/dist/libarchive: config_freebsd.h
config_windows.h
src/external/bsd/libarchive/dist/libarchive/test:
test_compat_gtar_1.tgz.uu test_pax_filename_encoding.tar.gz.uu
test_read_format_gtar_sparse_1_13.tgz.uu
test_read_format_gtar_sparse_1_17.tgz.uu
test_read_format_gtar_sparse_1_17_posix00.tgz.uu
test_read_format_gtar_sparse_1_17_posix01.tgz.uu
test_read_format_gtar_sparse_1_17_posix10.tgz.uu
test_read_format_isorr_bz2.iso.bz2.uu
src/external/bsd/libarchive/dist/tar: getdate.y matching.c siginfo.c
src/external/bsd/libarchive/dist/tar/test: test_option_T.c

Log Message:
Merge changes


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r0 src/external/bsd/libarchive/dist/cpio/err.c \
src/external/bsd/libarchive/dist/cpio/matching.c \
src/external/bsd/libarchive/dist/cpio/matching.h \
src/external/bsd/libarchive/dist/cpio/pathmatch.c \
src/external/bsd/libarchive/dist/cpio/pathmatch.h
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/libarchive/dist/cpio/test/test_option_B.c \
src/external/bsd/libarchive/dist/cpio/test/test_option_L.c \
src/external/bsd/libarchive/dist/cpio/test/test_option_ell.c
cvs rdiff -u -r1.2 -r1.3 \
src/external/bsd/libarchive/dist/libarchive/archive_read.3 \
src/external/bsd/libarchive/dist/libarchive/archive_write.3 \
src/external/bsd/libarchive/dist/libarchive/archive_write_disk.3
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/external/bsd/libarchive/dist/libarchive/archive_read_disk.3
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/libarchive/dist/libarchive/config_freebsd.h \
src/external/bsd/libarchive/dist/libarchive/config_windows.h
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/libarchive/dist/libarchive/test/test_compat_gtar_1.tgz.uu \

src/external/bsd/libarchive/dist/libarchive/test/test_pax_filename_encoding.tar.gz.uu
 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_format_gtar_sparse_1_13.tgz.uu
 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_format_gtar_sparse_1_17.tgz.uu
 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_format_gtar_sparse_1_17_posix00.tgz.uu
 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_format_gtar_sparse_1_17_posix01.tgz.uu
 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_format_gtar_sparse_1_17_posix10.tgz.uu
 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_format_isorr_bz2.iso.bz2.uu
cvs rdiff -u -r1.1.1.1 -r0 src/external/bsd/libarchive/dist/tar/getdate.y \
src/external/bsd/libarchive/dist/tar/matching.c \
src/external/bsd/libarchive/dist/tar/siginfo.c
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/libarchive/dist/tar/test/test_option_T.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/libarchive/dist/libarchive/archive_read.3
diff -u src/external/bsd/libarchive/dist/libarchive/archive_read.3:1.2 src/external/bsd/libarchive/dist/libarchive/archive_read.3:1.3
--- src/external/bsd/libarchive/dist/libarchive/archive_read.3:1.2	Thu Oct 15 17:26:57 2009
+++ src/external/bsd/libarchive/dist/libarchive/archive_read.3	Sat Feb 20 02:51:33 2010
@@ -22,23 +22,32 @@
 .\ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\ SUCH DAMAGE.
 .\
-.\ $FreeBSD: src/lib/libarchive/archive_read.3,v 1.37 2008/05/26 17:00:22 kientzle Exp $
+.\ $FreeBSD: head/lib/libarchive/archive_read.3 191595 2009-04-27 20:13:13Z kientzle $
 .\
-.Dd August 19, 2006
+.Dd April 13, 2009
 .Dt archive_read 3
 .Os
 .Sh NAME
 .Nm archive_read_new ,
+.Nm archive_read_set_filter_options ,
+.Nm archive_read_set_format_options ,
+.Nm archive_read_set_options ,
 .Nm archive_read_support_compression_all ,
 .Nm archive_read_support_compression_bzip2 ,
 .Nm archive_read_support_compression_compress ,
 .Nm archive_read_support_compression_gzip ,
+.Nm archive_read_support_compression_lzma ,
 .Nm archive_read_support_compression_none ,
+.Nm archive_read_support_compression_xz ,
 .Nm archive_read_support_compression_program ,
+.Nm archive_read_support_compression_program_signature ,
 .Nm archive_read_support_format_all ,
+.Nm archive_read_support_format_ar ,
 .Nm archive_read_support_format_cpio ,
 .Nm archive_read_support_format_empty ,
 .Nm archive_read_support_format_iso9660 ,
+.Nm 

CVS commit: src/external/bsd/libarchive/dist/libarchive

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Sat Feb 20 02:53:09 UTC 2010

Modified Files:
src/external/bsd/libarchive/dist/libarchive:
archive_read_disk_entry_from_file.c

Log Message:
Do not leak setup_xattr into the public namespace.


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r1.2 \

src/external/bsd/libarchive/dist/libarchive/archive_read_disk_entry_from_file.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/libarchive/dist/libarchive/archive_read_disk_entry_from_file.c
diff -u src/external/bsd/libarchive/dist/libarchive/archive_read_disk_entry_from_file.c:1.1.1.1 src/external/bsd/libarchive/dist/libarchive/archive_read_disk_entry_from_file.c:1.2
--- src/external/bsd/libarchive/dist/libarchive/archive_read_disk_entry_from_file.c:1.1.1.1	Sat Feb 20 02:48:29 2010
+++ src/external/bsd/libarchive/dist/libarchive/archive_read_disk_entry_from_file.c	Sat Feb 20 02:53:09 2010
@@ -430,11 +430,11 @@
  * to not include the system extattrs that hold ACLs; we handle
  * those separately.
  */
-int
+static int
 setup_xattr(struct archive_read_disk *a, struct archive_entry *entry,
 int namespace, const char *name, const char *fullname, int fd);
 
-int
+static int
 setup_xattr(struct archive_read_disk *a, struct archive_entry *entry,
 int namespace, const char *name, const char *fullname, int fd)
 {



CVS commit: src/external/cddl/osnet/dist

2010-02-19 Thread Darran Hunt
Module Name:src
Committed By:   darran
Date:   Sat Feb 20 04:34:48 UTC 2010

Update of /cvsroot/src/external/cddl/osnet/dist
In directory ivanova.netbsd.org:/tmp/cvs-serv22077

Log Message:
Import the rest of Opensolaris 20081117 needed for DTrace. No conflicts
with ZFS.


Status:

Vendor Tag: sun
Release Tags:   osnet-20081117

U src/external/cddl/osnet/dist/cmd/zdb/zdb_il.c
U src/external/cddl/osnet/dist/cmd/zdb/zdb.c
U src/external/cddl/osnet/dist/cmd/zfs/zfs_iter.c
U src/external/cddl/osnet/dist/cmd/zfs/zfs_iter.h
U src/external/cddl/osnet/dist/cmd/zfs/zfs_main.c
U src/external/cddl/osnet/dist/cmd/zfs/zfs_util.h
U src/external/cddl/osnet/dist/cmd/zpool/zpool_iter.c
U src/external/cddl/osnet/dist/cmd/zpool/zpool_main.c
U src/external/cddl/osnet/dist/cmd/zpool/zpool_util.c
U src/external/cddl/osnet/dist/cmd/zpool/zpool_util.h
U src/external/cddl/osnet/dist/cmd/zpool/zpool_vdev.c
U src/external/cddl/osnet/dist/cmd/ztest/ztest.c
N src/external/cddl/osnet/dist/cmd/dtrace/dtrace.c
N src/external/cddl/osnet/dist/cmd/dtrace/dtrace.1
U src/external/cddl/osnet/dist/lib/libefi/common/crc32_efi.c
U src/external/cddl/osnet/dist/lib/libnvpair/libnvpair.c
U src/external/cddl/osnet/dist/lib/libnvpair/libnvpair.h
U src/external/cddl/osnet/dist/lib/libnvpair/nvpair_alloc_system.c
U src/external/cddl/osnet/dist/lib/libshare/common/libshare.h
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_strtoint.c
U src/external/cddl/osnet/dist/lib/libuutil/common/libuutil_common.h
U src/external/cddl/osnet/dist/lib/libuutil/common/libuutil_impl.h
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_alloc.c
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_avl.c
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_dprintf.c
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_ident.c
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_list.c
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_misc.c
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_open.c
U src/external/cddl/osnet/dist/lib/libuutil/common/uu_pname.c
U src/external/cddl/osnet/dist/lib/libuutil/common/libuutil.h
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_util.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_changelist.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_config.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_dataset.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_graph.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_impl.h
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_import.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_mount.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_pool.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_sendrecv.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs_status.c
U src/external/cddl/osnet/dist/lib/libzfs/common/libzfs.h
U src/external/cddl/osnet/dist/lib/libzpool/common/taskq.c
U src/external/cddl/osnet/dist/lib/libzpool/common/util.c
N src/external/cddl/osnet/dist/lib/libctf/common/ctf_lib.c
N src/external/cddl/osnet/dist/lib/libctf/common/ctf_subr.c
N src/external/cddl/osnet/dist/lib/libctf/common/libctf.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/mknames.sh
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_aggregate.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/drti.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_consume.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_as.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_as.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_buf.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_buf.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_cc.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_cg.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_provider.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_decl.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_decl.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_dis.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_dof.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_dof.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_error.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_errtags.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_grammar.y
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_handle.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_ident.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_ident.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_impl.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_inttab.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_inttab.h
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_lex.l
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_link.c
N src/external/cddl/osnet/dist/lib/libdtrace/common/dt_list.c
N 

CVS commit: src/external/bsd/pkg_install/dist

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Sat Feb 20 04:42:00 UTC 2010

Update of /cvsroot/src/external/bsd/pkg_install/dist
In directory ivanova.netbsd.org:/tmp/cvs-serv10033

Log Message:
nstall-20100220:
Try harder to give the user an idea which file failed.
Addresses PR 42223.

Status:

Vendor Tag: PKGSRC
Release Tags:   pkg_install-20100220

U src/external/bsd/pkg_install/dist/add/add.h
U src/external/bsd/pkg_install/dist/add/main.c
U src/external/bsd/pkg_install/dist/add/perform.c
U src/external/bsd/pkg_install/dist/add/pkg_add.1
U src/external/bsd/pkg_install/dist/admin/audit.c
U src/external/bsd/pkg_install/dist/admin/admin.h
U src/external/bsd/pkg_install/dist/admin/audit-packages.sh.in
U src/external/bsd/pkg_install/dist/admin/check.c
U src/external/bsd/pkg_install/dist/admin/main.c
U src/external/bsd/pkg_install/dist/admin/download-vulnerability-list.sh.in
U src/external/bsd/pkg_install/dist/admin/pkg_admin.1
U src/external/bsd/pkg_install/dist/bpm/bpm.1
U src/external/bsd/pkg_install/dist/bpm/bpm.sh.in
U src/external/bsd/pkg_install/dist/create/build.c
U src/external/bsd/pkg_install/dist/create/create.h
U src/external/bsd/pkg_install/dist/create/main.c
U src/external/bsd/pkg_install/dist/create/perform.c
U src/external/bsd/pkg_install/dist/create/pl.c
U src/external/bsd/pkg_install/dist/create/pkg_create.1
U src/external/bsd/pkg_install/dist/create/util.c
U src/external/bsd/pkg_install/dist/delete/pkg_delete.1
U src/external/bsd/pkg_install/dist/delete/pkg_delete.c
U src/external/bsd/pkg_install/dist/info/info.h
U src/external/bsd/pkg_install/dist/info/main.c
U src/external/bsd/pkg_install/dist/info/perform.c
U src/external/bsd/pkg_install/dist/info/pkg_info.1
U src/external/bsd/pkg_install/dist/info/show.c
U src/external/bsd/pkg_install/dist/lib/automatic.c
U src/external/bsd/pkg_install/dist/lib/config.h.in
U src/external/bsd/pkg_install/dist/lib/conflicts.c
U src/external/bsd/pkg_install/dist/lib/decompress.c
U src/external/bsd/pkg_install/dist/lib/defs.h
U src/external/bsd/pkg_install/dist/lib/dewey.c
U src/external/bsd/pkg_install/dist/lib/dewey.h
U src/external/bsd/pkg_install/dist/lib/fexec.c
U src/external/bsd/pkg_install/dist/lib/file.c
U src/external/bsd/pkg_install/dist/lib/global.c
U src/external/bsd/pkg_install/dist/lib/gpgsig.c
U src/external/bsd/pkg_install/dist/lib/iterate.c
C src/external/bsd/pkg_install/dist/lib/lib.h
U src/external/bsd/pkg_install/dist/lib/license.c
U src/external/bsd/pkg_install/dist/lib/lpkg.c
U src/external/bsd/pkg_install/dist/lib/opattern.c
U src/external/bsd/pkg_install/dist/lib/parse-config.c
U src/external/bsd/pkg_install/dist/lib/pkcs7.c
U src/external/bsd/pkg_install/dist/lib/pkg_install.conf.5.in
U src/external/bsd/pkg_install/dist/lib/pkg_io.c
U src/external/bsd/pkg_install/dist/lib/pkg_signature.c
U src/external/bsd/pkg_install/dist/lib/pkg_summary.5
U src/external/bsd/pkg_install/dist/lib/pkgdb.c
U src/external/bsd/pkg_install/dist/lib/pkgsrc.7
C src/external/bsd/pkg_install/dist/lib/version.h
U src/external/bsd/pkg_install/dist/lib/plist.c
U src/external/bsd/pkg_install/dist/lib/remove.c
U src/external/bsd/pkg_install/dist/lib/str.c
U src/external/bsd/pkg_install/dist/lib/var.c
U src/external/bsd/pkg_install/dist/lib/version.c
U src/external/bsd/pkg_install/dist/lib/vulnerabilities-file.c
U src/external/bsd/pkg_install/dist/lib/xwrapper.c
U src/external/bsd/pkg_install/dist/x509/pkgsrc.cnf
U src/external/bsd/pkg_install/dist/x509/pkgsrc.sh
U src/external/bsd/pkg_install/dist/x509/signing.txt

2 conflicts created by this import.
Use the following command to help the merge:

cvs checkout -jPKGSRC:yesterday -jPKGSRC 
src/external/bsd/pkg_install/dist



CVS commit: src/external/bsd/pkg_install/dist/lib

2010-02-19 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Sat Feb 20 04:44:59 UTC 2010

Modified Files:
src/external/bsd/pkg_install/dist/lib: lib.h version.h

Log Message:
Merge


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/dist/lib/lib.h \
src/external/bsd/pkg_install/dist/lib/version.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/pkg_install/dist/lib/lib.h
diff -u src/external/bsd/pkg_install/dist/lib/lib.h:1.3 src/external/bsd/pkg_install/dist/lib/lib.h:1.4
--- src/external/bsd/pkg_install/dist/lib/lib.h:1.3	Wed Feb  3 19:31:49 2010
+++ src/external/bsd/pkg_install/dist/lib/lib.h	Sat Feb 20 04:44:59 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: lib.h,v 1.3 2010/02/03 19:31:49 joerg Exp $ */
+/* $NetBSD: lib.h,v 1.4 2010/02/20 04:44:59 joerg Exp $ */
 
 /* from FreeBSD Id: lib.h,v 1.25 1997/10/08 07:48:03 charnier Exp */
 
@@ -322,8 +322,8 @@
 struct archive;
 struct archive_entry;
 
-struct archive *open_archive(const char *);
-struct archive *find_archive(const char *, int);
+struct archive *open_archive(const char *, char **);
+struct archive *find_archive(const char *, int, char **);
 void	process_pkg_path(void);
 struct url *find_best_package(const char *, const char *, int);
 
@@ -391,8 +391,8 @@
 void pkg_install_show_variable(const char *);
 
 /* Package signature creation and validation */
-int pkg_verify_signature(struct archive **, struct archive_entry **, char **);
-int pkg_full_signature_check(struct archive **);
+int pkg_verify_signature(const char *, struct archive **, struct archive_entry **, char **);
+int pkg_full_signature_check(const char *, struct archive **);
 #ifdef HAVE_SSL
 void pkg_sign_x509(const char *, const char *, const char *, const char *);
 #endif
Index: src/external/bsd/pkg_install/dist/lib/version.h
diff -u src/external/bsd/pkg_install/dist/lib/version.h:1.3 src/external/bsd/pkg_install/dist/lib/version.h:1.4
--- src/external/bsd/pkg_install/dist/lib/version.h:1.3	Wed Feb  3 19:31:49 2010
+++ src/external/bsd/pkg_install/dist/lib/version.h	Sat Feb 20 04:44:59 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: version.h,v 1.3 2010/02/03 19:31:49 joerg Exp $	*/
+/*	$NetBSD: version.h,v 1.4 2010/02/20 04:44:59 joerg Exp $	*/
 
 /*
  * Copyright (c) 2001 Thomas Klausner.  All rights reserved.
@@ -27,6 +27,6 @@
 #ifndef _INST_LIB_VERSION_H_
 #define _INST_LIB_VERSION_H_
 
-#define PKGTOOLS_VERSION 20100204
+#define PKGTOOLS_VERSION 20100220
 
 #endif /* _INST_LIB_VERSION_H_ */



CVS commit: src/usr.bin/tic

2010-02-19 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Feb 20 06:08:01 UTC 2010

Modified Files:
src/usr.bin/tic: tic.c

Log Message:
Since tic is a host tool, we need to include host system header to get
definitions of le16dec() and le16enc().

Solves PR bin/42747 from Henning Petersen


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/usr.bin/tic/tic.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/tic/tic.c
diff -u src/usr.bin/tic/tic.c:1.6 src/usr.bin/tic/tic.c:1.7
--- src/usr.bin/tic/tic.c:1.6	Thu Feb 11 13:09:57 2010
+++ src/usr.bin/tic/tic.c	Sat Feb 20 06:08:01 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: tic.c,v 1.6 2010/02/11 13:09:57 roy Exp $ */
+/* $NetBSD: tic.c,v 1.7 2010/02/20 06:08:01 pgoyette Exp $ */
 
 /*
  * Copyright (c) 2009, 2010 The NetBSD Foundation, Inc.
@@ -32,9 +32,10 @@
 #endif
 
 #include sys/cdefs.h
-__RCSID($NetBSD: tic.c,v 1.6 2010/02/11 13:09:57 roy Exp $);
+__RCSID($NetBSD: tic.c,v 1.7 2010/02/20 06:08:01 pgoyette Exp $);
 
 #include sys/types.h
+#include sys/endian.h
 
 #include ctype.h
 #include err.h



CVS commit: src/usr.bin/tic

2010-02-19 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Feb 20 06:15:06 UTC 2010

Modified Files:
src/usr.bin/tic: tic.c

Log Message:
Wrap the include of sys/endian.h in #ifdef HAVE_SYS_ENDIAN_H to avoid
build issues on systems that don't have a sys/endian.h

Pointed out by joerg@


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/usr.bin/tic/tic.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/tic/tic.c
diff -u src/usr.bin/tic/tic.c:1.7 src/usr.bin/tic/tic.c:1.8
--- src/usr.bin/tic/tic.c:1.7	Sat Feb 20 06:08:01 2010
+++ src/usr.bin/tic/tic.c	Sat Feb 20 06:15:06 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: tic.c,v 1.7 2010/02/20 06:08:01 pgoyette Exp $ */
+/* $NetBSD: tic.c,v 1.8 2010/02/20 06:15:06 pgoyette Exp $ */
 
 /*
  * Copyright (c) 2009, 2010 The NetBSD Foundation, Inc.
@@ -32,10 +32,13 @@
 #endif
 
 #include sys/cdefs.h
-__RCSID($NetBSD: tic.c,v 1.7 2010/02/20 06:08:01 pgoyette Exp $);
+__RCSID($NetBSD: tic.c,v 1.8 2010/02/20 06:15:06 pgoyette Exp $);
 
 #include sys/types.h
+
+#ifdef HAVE_SYS_ENDIAN_H
 #include sys/endian.h
+#endif
 
 #include ctype.h
 #include err.h



CVS commit: src/usr.bin/tic

2010-02-19 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Feb 20 06:20:46 UTC 2010

Modified Files:
src/usr.bin/tic: tic.c

Log Message:
One more time - do this correctly.

Thanks, joerg.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/usr.bin/tic/tic.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/tic/tic.c
diff -u src/usr.bin/tic/tic.c:1.8 src/usr.bin/tic/tic.c:1.9
--- src/usr.bin/tic/tic.c:1.8	Sat Feb 20 06:15:06 2010
+++ src/usr.bin/tic/tic.c	Sat Feb 20 06:20:46 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: tic.c,v 1.8 2010/02/20 06:15:06 pgoyette Exp $ */
+/* $NetBSD: tic.c,v 1.9 2010/02/20 06:20:46 pgoyette Exp $ */
 
 /*
  * Copyright (c) 2009, 2010 The NetBSD Foundation, Inc.
@@ -32,11 +32,11 @@
 #endif
 
 #include sys/cdefs.h
-__RCSID($NetBSD: tic.c,v 1.8 2010/02/20 06:15:06 pgoyette Exp $);
+__RCSID($NetBSD: tic.c,v 1.9 2010/02/20 06:20:46 pgoyette Exp $);
 
 #include sys/types.h
 
-#ifdef HAVE_SYS_ENDIAN_H
+#if !HAVE_NBTOOL_CONFIG_H || HAVE_SYS_ENDIAN_H
 #include sys/endian.h
 #endif