CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-23 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sun Jun 23 06:27:38 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
Explain HAVE_VIS situation in a comment


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/external/bsd/tmux/usr.bin/tmux/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/bsd/tmux/usr.bin/tmux/Makefile
diff -u src/external/bsd/tmux/usr.bin/tmux/Makefile:1.35 src/external/bsd/tmux/usr.bin/tmux/Makefile:1.36
--- src/external/bsd/tmux/usr.bin/tmux/Makefile:1.35	Sat Jun 22 23:51:26 2024
+++ src/external/bsd/tmux/usr.bin/tmux/Makefile	Sun Jun 23 06:27:38 2024
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.35 2024/06/22 23:51:26 wiz Exp $
+# $NetBSD: Makefile,v 1.36 2024/06/23 06:27:38 wiz Exp $
 
 .include 
 
@@ -169,7 +169,18 @@ CPPFLAGS+=	-I${SRCDIR} -I${.CURDIR}
 # Would be nicer to stick this in a config.h file, but the upstream code
 # does not use one at this moment.
 
-# HAVE_REALLOCARRAY, HAVE_TREE_H, HAVE_VIS added manually; HAVE_BSD_GETOPT necessary due to local patches
+# HAVE_REALLOCARRAY, HAVE_TREE_H, HAVE_VIS added manually
+#
+# HAVE_BSD_GETOPT:
+# Use the NetBSD libc getopt functions instead of the compat functions
+# provided by tmux (done using a local patch).
+#
+# HAVE_VIS:
+# tmux assumes the OpenBSD variant of strnvis which has arguments
+# swapped compared to FreeBSD & NetBSD, see
+# https://github.com/tmux/tmux/pull/4015
+# We have a local patch that adapts the call to the NetBSD version,
+# so we don't need to use the compat code provided by tmux.
 CPPFLAGS+=	\
 -DHAVE_ASPRINTF=1 \
 -DHAVE_B64_NTOP=1 \



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-23 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sun Jun 23 06:27:38 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
Explain HAVE_VIS situation in a comment


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/external/bsd/tmux/usr.bin/tmux/Makefile

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



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:51:26 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
add generated tmux.1 to CLEANDIRFILES so it gets removed too


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/external/bsd/tmux/usr.bin/tmux/Makefile

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



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:51:26 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
add generated tmux.1 to CLEANDIRFILES so it gets removed too


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/external/bsd/tmux/usr.bin/tmux/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/bsd/tmux/usr.bin/tmux/Makefile
diff -u src/external/bsd/tmux/usr.bin/tmux/Makefile:1.34 src/external/bsd/tmux/usr.bin/tmux/Makefile:1.35
--- src/external/bsd/tmux/usr.bin/tmux/Makefile:1.34	Sat Jun 22 23:49:17 2024
+++ src/external/bsd/tmux/usr.bin/tmux/Makefile	Sat Jun 22 23:51:26 2024
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.34 2024/06/22 23:49:17 wiz Exp $
+# $NetBSD: Makefile,v 1.35 2024/06/22 23:51:26 wiz Exp $
 
 .include 
 
@@ -260,4 +260,6 @@ COPTS.window-copy.c+=	${CC_WNO_MAYBE_UNI
 tmux.1: $(SRCDIR)/tmux.1
 	sed -e 's|@SYSCONFDIR@|/etc|g' $> > $@
 
+CLEANDIRFILES+=	tmux.1
+
 .include 



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:49:17 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
notify.c is now sign-compare-safe


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/external/bsd/tmux/usr.bin/tmux/Makefile

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



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:49:17 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
notify.c is now sign-compare-safe


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/external/bsd/tmux/usr.bin/tmux/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/bsd/tmux/usr.bin/tmux/Makefile
diff -u src/external/bsd/tmux/usr.bin/tmux/Makefile:1.33 src/external/bsd/tmux/usr.bin/tmux/Makefile:1.34
--- src/external/bsd/tmux/usr.bin/tmux/Makefile:1.33	Sat Jun 22 20:08:16 2024
+++ src/external/bsd/tmux/usr.bin/tmux/Makefile	Sat Jun 22 23:49:17 2024
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.33 2024/06/22 20:08:16 wiz Exp $
+# $NetBSD: Makefile,v 1.34 2024/06/22 23:49:17 wiz Exp $
 
 .include 
 
@@ -250,7 +250,6 @@ DPADD+=		${LIBEVENT} ${LIBTERMINFO} ${LI
 
 COPTS.format.c += -Wno-format-nonliteral
 COPTS.input.c += -Wno-sign-compare -Wno-pointer-sign
-COPTS.notify.c += -Wno-sign-compare
 COPTS.tty.c += -Wno-pointer-sign
 COPTS.utempter.c+=	${CC_WNO_STRINGOP_TRUNCATION}
 COPTS.window-copy.c+=	${CC_WNO_MAYBE_UNINITIALIZED} -Wno-pointer-sign



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

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:45:53 UTC 2024

Modified Files:
src/external/bsd/tmux/dist: tty-term.c xmalloc.h
Removed Files:
src/external/bsd/tmux/dist: utmp.c

Log Message:
tmux: reduce diffs to upstream even more


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/external/bsd/tmux/dist/tty-term.c
cvs rdiff -u -r1.1 -r0 src/external/bsd/tmux/dist/utmp.c
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/tmux/dist/xmalloc.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/tmux/dist/tty-term.c
diff -u src/external/bsd/tmux/dist/tty-term.c:1.17 src/external/bsd/tmux/dist/tty-term.c:1.18
--- src/external/bsd/tmux/dist/tty-term.c:1.17	Sat Jun 22 20:07:14 2024
+++ src/external/bsd/tmux/dist/tty-term.c	Sat Jun 22 23:45:53 2024
@@ -778,7 +778,7 @@ tty_term_string_i(struct tty_term *term,
 #elif defined(HAVE_TIPARM)
 	s = tiparm(x, a);
 #else
-	s = tparm(x, a, 0, 0, 0, 0, 0, 0, 0, 0);
+	s = tparm((char *)x, a, 0, 0, 0, 0, 0, 0, 0, 0);
 #endif
 	if (s == NULL) {
 		log_debug("could not expand %s", tty_term_codes[code].name);
@@ -797,7 +797,7 @@ tty_term_string_ii(struct tty_term *term
 #elif defined(HAVE_TIPARM)
 	s = tiparm(x, a, b);
 #else
-	s = tparm(x, a, b, 0, 0, 0, 0, 0, 0, 0);
+	s = tparm((char *)x, a, b, 0, 0, 0, 0, 0, 0, 0);
 #endif
 	if (s == NULL) {
 		log_debug("could not expand %s", tty_term_codes[code].name);
@@ -817,7 +817,7 @@ tty_term_string_iii(struct tty_term *ter
 #elif defined(HAVE_TIPARM)
 	s = tiparm(x, a, b, c);
 #else
-	s = tparm(x, a, b, c, 0, 0, 0, 0, 0, 0);
+	s = tparm((char *)x, a, b, c, 0, 0, 0, 0, 0, 0);
 #endif
 	if (s == NULL) {
 		log_debug("could not expand %s", tty_term_codes[code].name);
@@ -836,7 +836,7 @@ tty_term_string_s(struct tty_term *term,
 #elif defined(HAVE_TIPARM)
 	s = tiparm(x, a);
 #else
-	s = tparm(x, (long)a, 0, 0, 0, 0, 0, 0, 0, 0);
+	s = tparm((char *)x, (long)a, 0, 0, 0, 0, 0, 0, 0, 0);
 #endif
 	if (s == NULL) {
 		log_debug("could not expand %s", tty_term_codes[code].name);
@@ -856,7 +856,7 @@ tty_term_string_ss(struct tty_term *term
 #elif defined(HAVE_TIPARM)
 	s = tiparm(x, a, b);
 #else
-	s = tparm(x, (long)a, (long)b, 0, 0, 0, 0, 0, 0, 0);
+	s = tparm((char *)x, (long)a, (long)b, 0, 0, 0, 0, 0, 0, 0);
 #endif
 	if (s == NULL) {
 		log_debug("could not expand %s", tty_term_codes[code].name);

Index: src/external/bsd/tmux/dist/xmalloc.h
diff -u src/external/bsd/tmux/dist/xmalloc.h:1.6 src/external/bsd/tmux/dist/xmalloc.h:1.7
--- src/external/bsd/tmux/dist/xmalloc.h:1.6	Wed Jun 28 22:21:26 2023
+++ src/external/bsd/tmux/dist/xmalloc.h	Sat Jun 22 23:45:53 2024
@@ -31,13 +31,13 @@ void	*xrecallocarray(void *, size_t, siz
 char	*xstrdup(const char *);
 char	*xstrndup(const char *, size_t);
 int	 xasprintf(char **, const char *, ...)
-		__attribute__((__format__ (__printf__, 2, 3)))
+		__attribute__((__format__ (printf, 2, 3)))
 		__attribute__((__nonnull__ (2)));
 int	 xvasprintf(char **, const char *, va_list)
 		__attribute__((__format__ (printf, 2, 0)))
 		__attribute__((__nonnull__ (2)));
 int	 xsnprintf(char *, size_t, const char *, ...)
-		__attribute__((__format__ (__printf__, 3, 4)))
+		__attribute__((__format__ (printf, 3, 4)))
 		__attribute__((__nonnull__ (3)))
 		__attribute__((__bounded__ (__string__, 1, 2)));
 int	 xvsnprintf(char *, size_t, const char *, va_list)



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

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:45:53 UTC 2024

Modified Files:
src/external/bsd/tmux/dist: tty-term.c xmalloc.h
Removed Files:
src/external/bsd/tmux/dist: utmp.c

Log Message:
tmux: reduce diffs to upstream even more


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/external/bsd/tmux/dist/tty-term.c
cvs rdiff -u -r1.1 -r0 src/external/bsd/tmux/dist/utmp.c
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/tmux/dist/xmalloc.h

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



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

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:33:50 UTC 2024

Modified Files:
src/external/bsd/tmux/dist: tmux.1

Log Message:
tmux: bump man page date to last release date (after import)


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/external/bsd/tmux/dist/tmux.1

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/tmux/dist/tmux.1
diff -u src/external/bsd/tmux/dist/tmux.1:1.17 src/external/bsd/tmux/dist/tmux.1:1.18
--- src/external/bsd/tmux/dist/tmux.1:1.17	Sat Jun 22 20:07:14 2024
+++ src/external/bsd/tmux/dist/tmux.1	Sat Jun 22 23:33:50 2024
@@ -14,7 +14,7 @@
 .\" IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
 .\" OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 .\"
-.Dd January 6, 2020
+.Dd February 13, 2024
 .Dt TMUX 1
 .Os
 .Sh NAME



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

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:33:50 UTC 2024

Modified Files:
src/external/bsd/tmux/dist: tmux.1

Log Message:
tmux: bump man page date to last release date (after import)


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/external/bsd/tmux/dist/tmux.1

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



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

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:33:20 UTC 2024

Modified Files:
src/external/bsd/tmux/dist: style.c

Log Message:
Reduce diff to upstream.

gcc bug workaround doesn't seem to be necessary any longer.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/tmux/dist/style.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/tmux/dist/style.c
diff -u src/external/bsd/tmux/dist/style.c:1.7 src/external/bsd/tmux/dist/style.c:1.8
--- src/external/bsd/tmux/dist/style.c:1.7	Sat Jun 22 20:07:14 2024
+++ src/external/bsd/tmux/dist/style.c	Sat Jun 22 23:33:20 2024
@@ -255,8 +255,6 @@ style_tostring(struct style *sy)
 			tmp = "left-marker";
 		else if (sy->list == STYLE_LIST_RIGHT_MARKER)
 			tmp = "right-marker";
-		else
-			abort();	// XXX: gcc
 		off += xsnprintf(s + off, sizeof s - off, "%slist=%s", comma,
 		tmp);
 		comma = ",";
@@ -279,8 +277,7 @@ style_tostring(struct style *sy)
 		} else if (sy->range_type == STYLE_RANGE_USER) {
 			snprintf(b, sizeof b, "user|%s", sy->range_string);
 			tmp = b;
-		} else
-			abort();	// XXX: gcc
+		}
 		off += xsnprintf(s + off, sizeof s - off, "%srange=%s", comma,
 		tmp);
 		comma = ",";



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

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 23:33:20 UTC 2024

Modified Files:
src/external/bsd/tmux/dist: style.c

Log Message:
Reduce diff to upstream.

gcc bug workaround doesn't seem to be necessary any longer.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/tmux/dist/style.c

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



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 20:08:16 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
Adapt build for tmux 3.4.


To generate a diff of this commit:
cvs rdiff -u -r1.32 -r1.33 src/external/bsd/tmux/usr.bin/tmux/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/bsd/tmux/usr.bin/tmux/Makefile
diff -u src/external/bsd/tmux/usr.bin/tmux/Makefile:1.32 src/external/bsd/tmux/usr.bin/tmux/Makefile:1.33
--- src/external/bsd/tmux/usr.bin/tmux/Makefile:1.32	Thu Jan  4 13:20:22 2024
+++ src/external/bsd/tmux/usr.bin/tmux/Makefile	Sat Jun 22 20:08:16 2024
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.32 2024/01/04 13:20:22 uwe Exp $
+# $NetBSD: Makefile,v 1.33 2024/06/22 20:08:16 wiz Exp $
 
 .include 
 
@@ -93,6 +93,9 @@ format.c \
 grid-reader.c \
 grid-view.c \
 grid.c \
+hyperlinks.c \
+image.c \
+image-sixel.c \
 input-keys.c \
 input.c \
 job.c \
@@ -132,6 +135,7 @@ tty-keys.c \
 tty-term.c \
 tty.c \
 utf8.c \
+utf8-combined.c \
 window-buffer.c \
 window-client.c \
 window-clock.c \
@@ -150,6 +154,8 @@ SRCS+=		imsg.c
 SRCS+=		fdforkpty.c
 SRCS+=		freezero.c
 SRCS+=		explicit_bzero.c
+SRCS+=		htonll.c
+SRCS+=		ntohll.c
 SRCS+=		recallocarray.c
 SRCS+=		getdtablecount.c
 #SRCS+=		strtonum.c
@@ -163,7 +169,7 @@ CPPFLAGS+=	-I${SRCDIR} -I${.CURDIR}
 # Would be nicer to stick this in a config.h file, but the upstream code
 # does not use one at this moment.
 
-# HAVE_REALLOCARRAY, HAVE_TREE_H, HAVE_VIS added manually; HAVE_BSD_GETOPT_H necessary due to local patches
+# HAVE_REALLOCARRAY, HAVE_TREE_H, HAVE_VIS added manually; HAVE_BSD_GETOPT necessary due to local patches
 CPPFLAGS+=	\
 -DHAVE_ASPRINTF=1 \
 -DHAVE_B64_NTOP=1 \
@@ -175,6 +181,7 @@ CPPFLAGS+=	\
 -DHAVE_CURSES_H=1 \
 -DHAVE_DAEMON=1 \
 -DHAVE_DIRENT_H=1 \
+-DENABLE_SIXEL=1 \
 -DHAVE_EVENT2_EVENT_H=1 \
 -DHAVE_FCNTL_CLOSEM=1 \
 -DHAVE_FCNTL_H=1 \
@@ -212,6 +219,7 @@ CPPFLAGS+=	\
 -DHAVE_SYS_STAT_H=1 \
 -DHAVE_SYS_TREE_H=1 \
 -DHAVE_SYS_TYPES_H=1 \
+-DHAVE_TIPARM=1 \
 -DHAVE_TREE_H=1 \
 -DHAVE_UNISTD_H=1 \
 -DHAVE_UTIL_H=1 \
@@ -220,17 +228,17 @@ CPPFLAGS+=	\
 -DPACKAGE=\"tmux\" \
 -DPACKAGE_BUGREPORT=\"\" \
 -DPACKAGE_NAME=\"tmux\" \
--DPACKAGE_STRING=\"tmux\ 3.3a\" \
+-DPACKAGE_STRING=\"tmux\ 3.4\" \
 -DPACKAGE_TARNAME=\"tmux\" \
 -DPACKAGE_URL=\"\" \
--DPACKAGE_VERSION=\"3.3a\" \
+-DPACKAGE_VERSION=\"3.4\" \
 -DSTDC_HEADERS=1 \
 -DTMUX_CONF='"/etc/tmux.conf:~/.tmux.conf:$XDG_CONFIG_HOME/tmux/tmux.conf:~/.config/tmux/tmux.conf"' \
+-DTMUX_LOCK_CMD='"lock -np"' \
 -DTMUX_TERM='"tmux-256color"' \
--DTMUX_VERSION='"3.3a"' \
--DVERSION=\"3.3a\" \
+-DTMUX_VERSION='"3.4"' \
+-DVERSION=\"3.4\" \
 -D_ALL_SOURCE=1 \
--D_FORTIFY_SOURCE=2 \
 -D_GNU_SOURCE=1 \
 -D_OPENBSD_SOURCE \
 -D_POSIX_PTHREAD_SEMANTICS=1 \



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 20:08:16 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
Adapt build for tmux 3.4.


To generate a diff of this commit:
cvs rdiff -u -r1.32 -r1.33 src/external/bsd/tmux/usr.bin/tmux/Makefile

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



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

2024-06-22 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sat Jun 22 20:07:14 UTC 2024

Modified Files:
src/external/bsd/tmux/dist: arguments.c client.c cmd-attach-session.c
cmd-capture-pane.c cmd-display-menu.c cmd-display-message.c
cmd-load-buffer.c cmd-new-session.c cmd-new-window.c cmd-parse.y
cmd-paste-buffer.c cmd-queue.c cmd-resize-window.c cmd-send-keys.c
cmd-split-window.c colour.c compat.h control.c environ.c format.c
grid.c hyperlinks.c image-sixel.c input-keys.c input.c
key-bindings.c menu.c mode-tree.c notify.c options.c paste.c proc.c
screen-write.c screen.c server-client.c server-fn.c server.c
session.c spawn.c status.c style.c tmux.1 tmux.c tmux.h tty-acs.c
tty-keys.c tty-term.c tty.c utf8.c window-buffer.c window-client.c
window-copy.c window-tree.c window.c
src/external/bsd/tmux/dist/compat: imsg-buffer.c imsg.c

Log Message:
Merge tmux-3.4, adding some build fixes.


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.12 -r1.2 src/external/bsd/tmux/dist/arguments.c
cvs rdiff -u -r1.12 -r1.13 src/external/bsd/tmux/dist/client.c \
src/external/bsd/tmux/dist/cmd-display-message.c \
src/external/bsd/tmux/dist/cmd-send-keys.c \
src/external/bsd/tmux/dist/grid.c \
src/external/bsd/tmux/dist/key-bindings.c
cvs rdiff -u -r1.10 -r1.11 src/external/bsd/tmux/dist/cmd-attach-session.c \
src/external/bsd/tmux/dist/cmd-capture-pane.c \
src/external/bsd/tmux/dist/cmd-new-window.c \
src/external/bsd/tmux/dist/cmd-paste-buffer.c \
src/external/bsd/tmux/dist/tty.c src/external/bsd/tmux/dist/window-tree.c
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/tmux/dist/cmd-display-menu.c \
src/external/bsd/tmux/dist/paste.c src/external/bsd/tmux/dist/style.c
cvs rdiff -u -r1.11 -r1.12 src/external/bsd/tmux/dist/cmd-load-buffer.c \
src/external/bsd/tmux/dist/cmd-new-session.c \
src/external/bsd/tmux/dist/cmd-split-window.c \
src/external/bsd/tmux/dist/colour.c src/external/bsd/tmux/dist/environ.c \
src/external/bsd/tmux/dist/server-client.c \
src/external/bsd/tmux/dist/tty-acs.c
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/tmux/dist/cmd-parse.y \
src/external/bsd/tmux/dist/spawn.c
cvs rdiff -u -r1.8 -r1.9 src/external/bsd/tmux/dist/cmd-queue.c \
src/external/bsd/tmux/dist/notify.c \
src/external/bsd/tmux/dist/window-client.c
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/tmux/dist/cmd-resize-window.c \
src/external/bsd/tmux/dist/compat.h src/external/bsd/tmux/dist/control.c \
src/external/bsd/tmux/dist/menu.c
cvs rdiff -u -r1.14 -r1.15 src/external/bsd/tmux/dist/format.c \
src/external/bsd/tmux/dist/screen-write.c \
src/external/bsd/tmux/dist/screen.c \
src/external/bsd/tmux/dist/server-fn.c \
src/external/bsd/tmux/dist/session.c src/external/bsd/tmux/dist/tmux.c
cvs rdiff -u -r1.1.1.1 -r1.2 src/external/bsd/tmux/dist/hyperlinks.c \
src/external/bsd/tmux/dist/image-sixel.c
cvs rdiff -u -r1.13 -r1.14 src/external/bsd/tmux/dist/input-keys.c \
src/external/bsd/tmux/dist/options.c
cvs rdiff -u -r1.17 -r1.18 src/external/bsd/tmux/dist/input.c \
src/external/bsd/tmux/dist/tty-keys.c
cvs rdiff -u -r1.9 -r1.10 src/external/bsd/tmux/dist/mode-tree.c \
src/external/bsd/tmux/dist/utf8.c \
src/external/bsd/tmux/dist/window-buffer.c
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/tmux/dist/proc.c
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/tmux/dist/server.c
cvs rdiff -u -r1.15 -r1.16 src/external/bsd/tmux/dist/status.c \
src/external/bsd/tmux/dist/window-copy.c
cvs rdiff -u -r1.16 -r1.17 src/external/bsd/tmux/dist/tmux.1 \
src/external/bsd/tmux/dist/tty-term.c src/external/bsd/tmux/dist/window.c
cvs rdiff -u -r1.21 -r1.22 src/external/bsd/tmux/dist/tmux.h
cvs rdiff -u -r1.10 -r1.11 src/external/bsd/tmux/dist/compat/imsg-buffer.c
cvs rdiff -u -r1.9 -r1.10 src/external/bsd/tmux/dist/compat/imsg.c

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



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

2024-06-13 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Thu Jun 13 23:24:25 UTC 2024

Modified Files:
src/external/bsd/libarchive/dist/libarchive/test:
test_read_disk_directory_traversals.c

Log Message:
PR/58342: Martin Husemann: NetBSD does not really support O_SEARCH


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.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/test/test_read_disk_directory_traversals.c
diff -u src/external/bsd/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c:1.3 src/external/bsd/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c:1.4
--- src/external/bsd/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c:1.3	Sun Jun  9 15:47:56 2024
+++ src/external/bsd/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c	Thu Jun 13 19:24:25 2024
@@ -1607,8 +1607,9 @@ test_parent(void)
 	int file_count;
 	int match_count;
 	int r;
-#if defined(O_PATH) || defined(O_SEARCH) || \
+#if defined(O_PATH) || (defined(O_SEARCH) && !defined(__NetBSD__)) || \
  (defined(__FreeBSD__) && defined(O_EXEC))
+#define IGNORE_TRAVERSALS_TEST4
 	const char *ignore_traversals_test4;
 
 	ignore_traversals_test4 = getenv("IGNORE_TRAVERSALS_TEST4");
@@ -1787,8 +1788,7 @@ test_parent(void)
 	archive_entry_clear(ae);
 	r = archive_read_next_header2(a, ae);
 	if (r == ARCHIVE_FAILED) {
-#if defined(O_PATH) || defined(O_SEARCH) || \
- (defined(__FreeBSD__) && defined(O_EXEC))
+#ifdef IGNORE_TRAVERSALS_TEST4
 		if (ignore_traversals_test4 == NULL)
 			assertEqualIntA(a, ARCHIVE_OK, r);
 #endif



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

2024-06-13 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Thu Jun 13 23:24:25 UTC 2024

Modified Files:
src/external/bsd/libarchive/dist/libarchive/test:
test_read_disk_directory_traversals.c

Log Message:
PR/58342: Martin Husemann: NetBSD does not really support O_SEARCH


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 \

src/external/bsd/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c

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



CVS commit: src/external/bsd/pkg_install

2024-06-11 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Tue Jun 11 10:18:11 UTC 2024

Modified Files:
src/external/bsd/pkg_install: prepare-import.sh
src/external/bsd/pkg_install/sbin/pkg_add: Makefile

Log Message:
Add new file for pkg_install-20240307, add import instructions.


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

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



CVS commit: src/external/bsd/pkg_install

2024-06-11 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Tue Jun 11 10:18:11 UTC 2024

Modified Files:
src/external/bsd/pkg_install: prepare-import.sh
src/external/bsd/pkg_install/sbin/pkg_add: Makefile

Log Message:
Add new file for pkg_install-20240307, add import instructions.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/pkg_install/prepare-import.sh
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/sbin/pkg_add/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/bsd/pkg_install/prepare-import.sh
diff -u src/external/bsd/pkg_install/prepare-import.sh:1.4 src/external/bsd/pkg_install/prepare-import.sh:1.5
--- src/external/bsd/pkg_install/prepare-import.sh:1.4	Sat Apr 20 15:30:34 2013
+++ src/external/bsd/pkg_install/prepare-import.sh	Tue Jun 11 10:18:11 2024
@@ -1,9 +1,14 @@
 #!/bin/sh
-# $NetBSD: prepare-import.sh,v 1.4 2013/04/20 15:30:34 wiz Exp $
+# $NetBSD: prepare-import.sh,v 1.5 2024/06/11 10:18:11 wiz Exp $
 #
 # Copy new pkgsrc/pkgtools/pkg_install/files to dist.
 # Run this script and check for additional files and
 # directories to prune, only relevant content is included.
+#
+# Import with:
+#
+# cd dist
+# cvs -d cvs.netbsd.org:/cvsroot import -m "Import pkg_install 20xx from pkgsrc" src/external/bsd/pkg_install/dist PKGSRC pkg_install-20xx
 
 set -e
 

Index: src/external/bsd/pkg_install/sbin/pkg_add/Makefile
diff -u src/external/bsd/pkg_install/sbin/pkg_add/Makefile:1.3 src/external/bsd/pkg_install/sbin/pkg_add/Makefile:1.4
--- src/external/bsd/pkg_install/sbin/pkg_add/Makefile:1.3	Thu Apr 20 13:18:47 2017
+++ src/external/bsd/pkg_install/sbin/pkg_add/Makefile	Tue Jun 11 10:18:11 2024
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.3 2017/04/20 13:18:47 joerg Exp $
+# $NetBSD: Makefile,v 1.4 2024/06/11 10:18:11 wiz Exp $
 # Original from FreeBSD, no rcs id.
 
 PROG= pkg_add
-SRCS= main.c perform.c
+SRCS= main.c parse_cross.c perform.c
 
 .include 
 



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

2024-06-11 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Tue Jun 11 09:26:58 UTC 2024

Modified Files:
src/external/bsd/pkg_install/dist/add: add.h main.c perform.c
src/external/bsd/pkg_install/dist/admin: main.c
src/external/bsd/pkg_install/dist/create: util.c
src/external/bsd/pkg_install/dist/lib: dewey.c fexec.c license.c
pkg_install.conf.5.in pkg_io.c version.h
src/external/bsd/pkg_install/dist/x509: pkgsrc.cnf

Log Message:
Merge pkg_install-20240307


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/dist/add/add.h
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/pkg_install/dist/add/main.c
cvs rdiff -u -r1.10 -r1.11 src/external/bsd/pkg_install/dist/add/perform.c
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/pkg_install/dist/admin/main.c
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/pkg_install/dist/create/util.c
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/pkg_install/dist/lib/dewey.c \
src/external/bsd/pkg_install/dist/lib/pkg_install.conf.5.in
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/dist/lib/fexec.c
cvs rdiff -u -r1.11 -r1.12 src/external/bsd/pkg_install/dist/lib/license.c
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/pkg_install/dist/lib/pkg_io.c
cvs rdiff -u -r1.20 -r1.21 src/external/bsd/pkg_install/dist/lib/version.h
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/dist/x509/pkgsrc.cnf

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/add/add.h
diff -u src/external/bsd/pkg_install/dist/add/add.h:1.3 src/external/bsd/pkg_install/dist/add/add.h:1.4
--- src/external/bsd/pkg_install/dist/add/add.h:1.3	Sat Apr 10 19:49:59 2021
+++ src/external/bsd/pkg_install/dist/add/add.h	Tue Jun 11 09:26:57 2024
@@ -1,4 +1,4 @@
-/* $NetBSD: add.h,v 1.3 2021/04/10 19:49:59 nia Exp $ */
+/* $NetBSD: add.h,v 1.4 2024/06/11 09:26:57 wiz Exp $ */
 
 /* from FreeBSD Id: add.h,v 1.8 1997/02/22 16:09:15 peter Exp  */
 
@@ -27,6 +27,8 @@
 
 extern char *Destdir;
 extern char *OverrideMachine;
+extern char *OverrideOpsys;
+extern char *OverrideOSVersion;
 extern char *Prefix;
 extern char *View;
 extern char *Viewbase;
@@ -42,6 +44,8 @@ extern int ReplaceSame;
 extern Boolean ForceDepends;
 extern Boolean ForceDepending;
 
+void	parse_cross(const char *, char **, char **, char **);
+
 int make_hierarchy(char *);
 voidapply_perms(char *, char **, int);
 

Index: src/external/bsd/pkg_install/dist/add/main.c
diff -u src/external/bsd/pkg_install/dist/add/main.c:1.4 src/external/bsd/pkg_install/dist/add/main.c:1.5
--- src/external/bsd/pkg_install/dist/add/main.c:1.4	Sat Apr 10 22:59:46 2021
+++ src/external/bsd/pkg_install/dist/add/main.c	Tue Jun 11 09:26:57 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: main.c,v 1.4 2021/04/10 22:59:46 wiz Exp $	*/
+/*	$NetBSD: main.c,v 1.5 2024/06/11 09:26:57 wiz Exp $	*/
 
 #if HAVE_CONFIG_H
 #include "config.h"
@@ -7,7 +7,7 @@
 #if HAVE_SYS_CDEFS_H
 #include 
 #endif
-__RCSID("$NetBSD: main.c,v 1.4 2021/04/10 22:59:46 wiz Exp $");
+__RCSID("$NetBSD: main.c,v 1.5 2024/06/11 09:26:57 wiz Exp $");
 
 /*
  *
@@ -40,6 +40,8 @@ static char Options[] = "AC:DIK:P:RVfhm:
 
 char   *Destdir = NULL;
 char   *OverrideMachine = NULL;
+char   *OverrideOpsys = NULL;
+char   *OverrideOSVersion = NULL;
 char   *Prefix = NULL;
 Boolean NoInstall = FALSE;
 Boolean NoRecord = FALSE;
@@ -110,7 +112,8 @@ main(int argc, char **argv)
 			break;
 
 		case 'm':
-			OverrideMachine = optarg;
+			parse_cross(optarg, , ,
+			);
 			break;
 
 		case 'n':

Index: src/external/bsd/pkg_install/dist/add/perform.c
diff -u src/external/bsd/pkg_install/dist/add/perform.c:1.10 src/external/bsd/pkg_install/dist/add/perform.c:1.11
--- src/external/bsd/pkg_install/dist/add/perform.c:1.10	Sat Apr 10 20:07:57 2021
+++ src/external/bsd/pkg_install/dist/add/perform.c	Tue Jun 11 09:26:57 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: perform.c,v 1.10 2021/04/10 20:07:57 nia Exp $	*/
+/*	$NetBSD: perform.c,v 1.11 2024/06/11 09:26:57 wiz Exp $	*/
 #if HAVE_CONFIG_H
 #include "config.h"
 #endif
@@ -6,7 +6,7 @@
 #if HAVE_SYS_CDEFS_H
 #include 
 #endif
-__RCSID("$NetBSD: perform.c,v 1.10 2021/04/10 20:07:57 nia Exp $");
+__RCSID("$NetBSD: perform.c,v 1.11 2024/06/11 09:26:57 wiz Exp $");
 
 /*-
  * Copyright (c) 2003 Grant Beattie 
@@ -893,19 +893,28 @@ check_platform(struct pkg_task *pkg)
 {
 	struct utsname host_uname;
 	const char *effective_arch;
+	const char *effective_opsys;
+	const char *effective_os_version;
 	int fatal;
 
-	if (uname(_uname) < 0) {
-		if (Force) {
-			warnx("uname() failed, continuing.");
-			return 0;
-		} else {
-			warnx("uname() failed, aborting.");
-			return -1;
+if (OverrideOpsys != NULL && OverrideOSVersion != NULL) {
+		effective_opsys = OverrideOpsys;
+		effective_os_version = OverrideOSVersion;
+	} else {
+		if (uname(_uname) < 0) {
+			if (Force) {
+warnx("uname() failed, continuing.");
+

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

2024-06-11 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Tue Jun 11 09:26:58 UTC 2024

Modified Files:
src/external/bsd/pkg_install/dist/add: add.h main.c perform.c
src/external/bsd/pkg_install/dist/admin: main.c
src/external/bsd/pkg_install/dist/create: util.c
src/external/bsd/pkg_install/dist/lib: dewey.c fexec.c license.c
pkg_install.conf.5.in pkg_io.c version.h
src/external/bsd/pkg_install/dist/x509: pkgsrc.cnf

Log Message:
Merge pkg_install-20240307


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/dist/add/add.h
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/pkg_install/dist/add/main.c
cvs rdiff -u -r1.10 -r1.11 src/external/bsd/pkg_install/dist/add/perform.c
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/pkg_install/dist/admin/main.c
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/pkg_install/dist/create/util.c
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/pkg_install/dist/lib/dewey.c \
src/external/bsd/pkg_install/dist/lib/pkg_install.conf.5.in
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/dist/lib/fexec.c
cvs rdiff -u -r1.11 -r1.12 src/external/bsd/pkg_install/dist/lib/license.c
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/pkg_install/dist/lib/pkg_io.c
cvs rdiff -u -r1.20 -r1.21 src/external/bsd/pkg_install/dist/lib/version.h
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/pkg_install/dist/x509/pkgsrc.cnf

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



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

2024-06-09 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun  9 23:58:23 UTC 2024

Modified Files:
src/external/bsd/libarchive/dist/libarchive/test:
test_write_disk_secure.c

Log Message:
libarchive test_write_disk_secure.c: Restore hunk of local change.

This was part of a change added in revision 1.4 in order to avoid
cluttering /tmp (PR 55612), and lost in the 3.7.4 merge:

https://mail-index.netbsd.org/source-changes/2020/08/28/msg121149.html


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/bsd/libarchive/dist/libarchive/test/test_write_disk_secure.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/test/test_write_disk_secure.c
diff -u src/external/bsd/libarchive/dist/libarchive/test/test_write_disk_secure.c:1.5 src/external/bsd/libarchive/dist/libarchive/test/test_write_disk_secure.c:1.6
--- src/external/bsd/libarchive/dist/libarchive/test/test_write_disk_secure.c:1.5	Sun Jun  9 19:47:56 2024
+++ src/external/bsd/libarchive/dist/libarchive/test/test_write_disk_secure.c	Sun Jun  9 23:58:23 2024
@@ -39,6 +39,16 @@ DEFINE_TEST(test_write_disk_secure)
 	struct archive *a;
 	struct archive_entry *ae;
 	struct stat st;
+	char tmp[2048];
+	const char *tmpdir;
+	const char *lname =
+	"libarchive_test-test_write_disk_secure-absolute_symlink";
+#if 0
+	const char *fname =
+	"libarchive_test-test_write_disk_secure-absolute_symlink_path.tmp";
+#endif
+	const char *pname =
+	"libarchive_test-test_write_disk_secure-absolute_path.tmp";
 #if defined(HAVE_LCHMOD) && defined(HAVE_SYMLINK) && \
 defined(S_IRUSR) && defined(S_IWUSR) && defined(S_IXUSR)
 	int working_lchmod;



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

2024-06-09 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Sun Jun  9 23:58:23 UTC 2024

Modified Files:
src/external/bsd/libarchive/dist/libarchive/test:
test_write_disk_secure.c

Log Message:
libarchive test_write_disk_secure.c: Restore hunk of local change.

This was part of a change added in revision 1.4 in order to avoid
cluttering /tmp (PR 55612), and lost in the 3.7.4 merge:

https://mail-index.netbsd.org/source-changes/2020/08/28/msg121149.html


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/bsd/libarchive/dist/libarchive/test/test_write_disk_secure.c

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



CVS commit: src/external/bsd/libarchive

2024-06-09 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Jun  9 19:47:56 UTC 2024

Modified Files:
src/external/bsd/libarchive: prepare-import.sh
src/external/bsd/libarchive/dist/cpio/test: test_basic.c
test_format_newc.c
src/external/bsd/libarchive/dist/libarchive: archive.h
archive_check_magic.c archive_entry.3 archive_openssl_evp_private.h
archive_openssl_hmac_private.h archive_pack_dev.c
archive_pack_dev.h archive_private.h archive_read.3 archive_read.c
archive_read_disk.3 archive_read_disk_entry_from_file.c
archive_read_disk_posix.c archive_read_open_filename.c
archive_read_support_format_iso9660.c
archive_read_support_format_mtree.c
archive_read_support_format_warc.c
archive_read_support_format_xar.c archive_util.3 archive_util.c
archive_write.3 archive_write_disk.3 archive_write_disk_posix.c
archive_write_set_format_ar.c archive_write_set_format_shar.c
archive_write_set_format_ustar.c libarchive-formats.5 libarchive.3
libarchive_internals.3 tar.5
src/external/bsd/libarchive/dist/libarchive/test:
test_acl_platform_nfs4.c test_acl_platform_posix1e.c
test_archive_write_set_format_filter_by_ext.c test_compat_zip.c
test_fuzz.c test_read_disk_directory_traversals.c
test_read_extract.c test_read_format_7zip.c
test_read_format_gtar_sparse.c test_read_format_zip.c
test_read_format_zip_7075_utf8_paths.c
test_read_format_zip_comment_stored.c
test_read_format_zip_high_compression.c test_read_format_zip_jar.c
test_read_format_zip_mac_metadata.c
test_read_format_zip_malformed.c test_read_format_zip_nested.c
test_read_format_zip_nofiletype.c test_read_format_zip_padded.c
test_read_format_zip_sfx.c
test_read_format_zip_with_invalid_traditional_eocd.c
test_read_format_zip_zip64.c test_read_pax_truncated.c
test_read_truncated_filter.c test_sparse_basic.c test_write_disk.c
test_write_disk_secure.c test_write_disk_secure744.c
test_write_disk_secure746.c test_write_format_cpio_empty.c
test_write_format_shar_empty.c test_write_format_tar.c
test_write_format_tar_sparse.c test_write_format_zip_file.c
test_write_format_zip_file_zip64.c
src/external/bsd/libarchive/dist/libarchive_fe: err.c err.h
src/external/bsd/libarchive/dist/tar: bsdtar.c write.c
src/external/bsd/libarchive/dist/tar/test: test_basic.c test_copy.c
test_option_C_upper.c test_option_U_upper.c test_option_s.c
test_symlink_dir.c
src/external/bsd/libarchive/dist/test_utils: test_common.h test_main.c
test_utils.c test_utils.h
src/external/bsd/libarchive/include: config_netbsd.h
src/external/bsd/libarchive/lib/libarchive: Makefile shlib_version
Removed Files:
src/external/bsd/libarchive/dist: CONTRIBUTING.md
src/external/bsd/libarchive/dist/libarchive/test:
test_compat_pax_libarchive_2x.c
test_compat_pax_libarchive_2x.tar.Z.uu test_read_pax_schily_xattr.c
test_read_pax_schily_xattr.tar.uu

Log Message:
Merge conflicts from 3.4.0 to 3.7.4


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/libarchive/prepare-import.sh
cvs rdiff -u -r1.1.1.1 -r0 src/external/bsd/libarchive/dist/CONTRIBUTING.md
cvs rdiff -u -r1.2 -r1.3 \
src/external/bsd/libarchive/dist/cpio/test/test_basic.c
cvs rdiff -u -r1.3 -r1.4 \
src/external/bsd/libarchive/dist/cpio/test/test_format_newc.c
cvs rdiff -u -r1.5 -r1.6 \
src/external/bsd/libarchive/dist/libarchive/archive.h \
src/external/bsd/libarchive/dist/libarchive/archive_entry.3 \
src/external/bsd/libarchive/dist/libarchive/archive_read_disk.3 \
src/external/bsd/libarchive/dist/libarchive/archive_write_disk.3
cvs rdiff -u -r1.3 -r1.4 \
src/external/bsd/libarchive/dist/libarchive/archive_check_magic.c \
src/external/bsd/libarchive/dist/libarchive/archive_openssl_evp_private.h \
src/external/bsd/libarchive/dist/libarchive/archive_pack_dev.c \
src/external/bsd/libarchive/dist/libarchive/archive_pack_dev.h \
src/external/bsd/libarchive/dist/libarchive/archive_read_disk_posix.c \
src/external/bsd/libarchive/dist/libarchive/archive_util.3 \
src/external/bsd/libarchive/dist/libarchive/libarchive-formats.5 \
src/external/bsd/libarchive/dist/libarchive/libarchive.3 \
src/external/bsd/libarchive/dist/libarchive/libarchive_internals.3 \
src/external/bsd/libarchive/dist/libarchive/tar.5
cvs rdiff -u -r1.4 -r1.5 \
src/external/bsd/libarchive/dist/libarchive/archive_openssl_hmac_private.h \

src/external/bsd/libarchive/dist/libarchive/archive_read_support_format_iso9660.c
 \

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

2024-05-24 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Fri May 24 16:09:09 UTC 2024

Modified Files:
src/external/bsd/dhcpcd/dist/src: dhcp6.c dhcpcd.c

Log Message:
Sync with dhcpcd-10.0.8


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/external/bsd/dhcpcd/dist/src/dhcp6.c
cvs rdiff -u -r1.55 -r1.56 src/external/bsd/dhcpcd/dist/src/dhcpcd.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/dhcpcd/dist/src/dhcp6.c
diff -u src/external/bsd/dhcpcd/dist/src/dhcp6.c:1.33 src/external/bsd/dhcpcd/dist/src/dhcp6.c:1.34
--- src/external/bsd/dhcpcd/dist/src/dhcp6.c:1.33	Fri May 24 11:30:29 2024
+++ src/external/bsd/dhcpcd/dist/src/dhcp6.c	Fri May 24 16:09:09 2024
@@ -3494,7 +3494,7 @@ dhcp6_recvif(struct interface *ifp, cons
 			 * To keep the same behaviour we won't do anything with
 			 * this. In the future we should make a lists of
 			 * ADVERTS and pick the "best" one. */
-			logdebugx("%s: discarding ADVERTISMENT from %s",
+			logdebugx("%s: discarding ADVERTISEMENT from %s",
 			ifp->name, sfrom);
 			return;
 		}

Index: src/external/bsd/dhcpcd/dist/src/dhcpcd.c
diff -u src/external/bsd/dhcpcd/dist/src/dhcpcd.c:1.55 src/external/bsd/dhcpcd/dist/src/dhcpcd.c:1.56
--- src/external/bsd/dhcpcd/dist/src/dhcpcd.c:1.55	Fri May 24 11:30:29 2024
+++ src/external/bsd/dhcpcd/dist/src/dhcpcd.c	Fri May 24 16:09:09 2024
@@ -423,8 +423,8 @@ dhcpcd_drop_af(struct interface *ifp, in
 #endif
 #ifdef ARP
 		arp_drop(ifp);
-	}
 #endif
+	}
 
 #if !defined(DHCP6) && !defined(DHCP)
 	UNUSED(stop);



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

2024-05-24 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Fri May 24 16:09:09 UTC 2024

Modified Files:
src/external/bsd/dhcpcd/dist/src: dhcp6.c dhcpcd.c

Log Message:
Sync with dhcpcd-10.0.8


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/external/bsd/dhcpcd/dist/src/dhcp6.c
cvs rdiff -u -r1.55 -r1.56 src/external/bsd/dhcpcd/dist/src/dhcpcd.c

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



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

2024-05-24 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Fri May 24 11:30:29 UTC 2024

Modified Files:
src/external/bsd/dhcpcd/dist/hooks: 30-hostname
src/external/bsd/dhcpcd/dist/src: dhcp.c dhcp6.c dhcpcd.c if-bsd.c
if-options.c ipv6.c ipv6nd.c logerr.c privsep.c

Log Message:
Sync with dhcpcd-10.0.7


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/dhcpcd/dist/hooks/30-hostname
cvs rdiff -u -r1.50 -r1.51 src/external/bsd/dhcpcd/dist/src/dhcp.c
cvs rdiff -u -r1.32 -r1.33 src/external/bsd/dhcpcd/dist/src/dhcp6.c
cvs rdiff -u -r1.54 -r1.55 src/external/bsd/dhcpcd/dist/src/dhcpcd.c
cvs rdiff -u -r1.30 -r1.31 src/external/bsd/dhcpcd/dist/src/if-bsd.c \
src/external/bsd/dhcpcd/dist/src/ipv6nd.c
cvs rdiff -u -r1.36 -r1.37 src/external/bsd/dhcpcd/dist/src/if-options.c
cvs rdiff -u -r1.18 -r1.19 src/external/bsd/dhcpcd/dist/src/ipv6.c \
src/external/bsd/dhcpcd/dist/src/privsep.c
cvs rdiff -u -r1.13 -r1.14 src/external/bsd/dhcpcd/dist/src/logerr.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/dhcpcd/dist/hooks/30-hostname
diff -u src/external/bsd/dhcpcd/dist/hooks/30-hostname:1.6 src/external/bsd/dhcpcd/dist/hooks/30-hostname:1.7
--- src/external/bsd/dhcpcd/dist/hooks/30-hostname:1.6	Fri Apr 21 16:54:26 2023
+++ src/external/bsd/dhcpcd/dist/hooks/30-hostname	Fri May 24 11:30:29 2024
@@ -118,7 +118,7 @@ set_hostname()
 	*)	hshort=true;;
 	esac
 
-	need_hostname || return
+	need_hostname || return 0
 
 	if [ -n "$new_fqdn" ]; then
 		if ${hfqdn} || ! ${hshort}; then

Index: src/external/bsd/dhcpcd/dist/src/dhcp.c
diff -u src/external/bsd/dhcpcd/dist/src/dhcp.c:1.50 src/external/bsd/dhcpcd/dist/src/dhcp.c:1.51
--- src/external/bsd/dhcpcd/dist/src/dhcp.c:1.50	Mon Dec 18 15:51:28 2023
+++ src/external/bsd/dhcpcd/dist/src/dhcp.c	Fri May 24 11:30:29 2024
@@ -1877,13 +1877,13 @@ dhcp_discover(void *arg)
 	dhcp_new_xid(ifp);
 	eloop_timeout_delete(ifp->ctx->eloop, NULL, ifp);
 	if (!(state->added & STATE_EXPIRED)) {
-		if (ifo->fallback)
+		if (ifo->fallback && ifo->fallback_time)
 			eloop_timeout_add_sec(ifp->ctx->eloop,
-			ifo->reboot, dhcp_fallback, ifp);
+			ifo->fallback_time, dhcp_fallback, ifp);
 #ifdef IPV4LL
 		else if (ifo->options & DHCPCD_IPV4LL)
 			eloop_timeout_add_sec(ifp->ctx->eloop,
-			ifo->reboot, ipv4ll_start, ifp);
+			ifo->ipv4ll_time, ipv4ll_start, ifp);
 #endif
 	}
 	if (ifo->options & DHCPCD_REQUEST)
@@ -1914,11 +1914,13 @@ dhcp_request(void *arg)
 {
 	struct interface *ifp = arg;
 	struct dhcp_state *state = D_STATE(ifp);
+	struct if_options *ifo = ifp->options;
 
 	state->state = DHS_REQUEST;
 	// Handle the server being silent to our request.
-	eloop_timeout_add_sec(ifp->ctx->eloop, ifp->options->reboot,
-	dhcp_requestfailed, ifp);
+	if (ifo->request_time != 0)
+		eloop_timeout_add_sec(ifp->ctx->eloop, ifo->request_time,
+		dhcp_requestfailed, ifp);
 	send_request(ifp);
 }
 
@@ -1944,7 +1946,11 @@ dhcp_expire(void *arg)
 static void
 dhcp_decline(struct interface *ifp)
 {
+	struct dhcp_state *state = D_STATE(ifp);
 
+	// Set the expired state so we send over BPF as this could be
+	// an address defence failure.
+	state->added |= STATE_EXPIRED;
 	send_message(ifp, DHCP_DECLINE, NULL);
 }
 #endif
@@ -2098,8 +2104,12 @@ static void
 dhcp_arp_defend_failed(struct arp_state *astate)
 {
 	struct interface *ifp = astate->iface;
+	struct dhcp_state *state = D_STATE(ifp);
 
+	if (!(ifp->options->options & (DHCPCD_INFORM | DHCPCD_STATIC)))
+		dhcp_decline(ifp);
 	dhcp_drop(ifp, "EXPIRED");
+	dhcp_unlink(ifp->ctx, state->leasefile);
 	dhcp_start1(ifp);
 }
 #endif
@@ -2740,7 +2750,7 @@ dhcp_reboot(struct interface *ifp)
 	/* Need to add this before dhcp_expire and friends. */
 	if (!ifo->fallback && ifo->options & DHCPCD_IPV4LL)
 		eloop_timeout_add_sec(ifp->ctx->eloop,
-		ifo->reboot, ipv4ll_start, ifp);
+		ifo->ipv4ll_time, ipv4ll_start, ifp);
 #endif
 
 	if (ifo->options & DHCPCD_LASTLEASE && state->lease.frominfo)
@@ -3199,8 +3209,8 @@ dhcp_handledhcp(struct interface *ifp, s
 
 	if (has_option_mask(ifo->requestmask, DHO_IPV6_PREFERRED_ONLY)) {
 		if (get_option_uint32(ifp->ctx, _time, bootp, bootp_len,
-		DHO_IPV6_PREFERRED_ONLY) == 0 &&
-		(state->state == DHS_DISCOVER || state->state == DHS_REBOOT))
+		DHO_IPV6_PREFERRED_ONLY) == 0 && (state->state == DHS_DISCOVER ||
+		state->state == DHS_REBOOT || state->state == DHS_NONE))
 		{
 			char v6msg[128];
 
@@ -3524,12 +3534,6 @@ dhcp_handlebootp(struct interface *ifp, 
 {
 	size_t v;
 
-	if (len < offsetof(struct bootp, vend)) {
-		logerrx("%s: truncated packet (%zu) from %s",
-		ifp->name, len, inet_ntoa(*from));
-		return;
-	}
-
 	/* Unlikely, but appeases sanitizers. */
 	if (len > FRAMELEN_MAX) {
 		logerrx("%s: packet exceeded frame length (%zu) from %s",
@@ -3662,6 +3666,13 @@ dhcp_recvmsg(struct dhcpcd_ctx *ctx, str
 	

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

2024-05-24 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Fri May 24 11:30:29 UTC 2024

Modified Files:
src/external/bsd/dhcpcd/dist/hooks: 30-hostname
src/external/bsd/dhcpcd/dist/src: dhcp.c dhcp6.c dhcpcd.c if-bsd.c
if-options.c ipv6.c ipv6nd.c logerr.c privsep.c

Log Message:
Sync with dhcpcd-10.0.7


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/dhcpcd/dist/hooks/30-hostname
cvs rdiff -u -r1.50 -r1.51 src/external/bsd/dhcpcd/dist/src/dhcp.c
cvs rdiff -u -r1.32 -r1.33 src/external/bsd/dhcpcd/dist/src/dhcp6.c
cvs rdiff -u -r1.54 -r1.55 src/external/bsd/dhcpcd/dist/src/dhcpcd.c
cvs rdiff -u -r1.30 -r1.31 src/external/bsd/dhcpcd/dist/src/if-bsd.c \
src/external/bsd/dhcpcd/dist/src/ipv6nd.c
cvs rdiff -u -r1.36 -r1.37 src/external/bsd/dhcpcd/dist/src/if-options.c
cvs rdiff -u -r1.18 -r1.19 src/external/bsd/dhcpcd/dist/src/ipv6.c \
src/external/bsd/dhcpcd/dist/src/privsep.c
cvs rdiff -u -r1.13 -r1.14 src/external/bsd/dhcpcd/dist/src/logerr.c

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



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

2024-05-24 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Fri May 24 07:52:46 UTC 2024

Modified Files:
src/external/bsd/tre/dist/src: agrep.c

Log Message:
agrep(1): remove duplicated and obsolete imports.

dirent import is the only one which stays in the odd location.

Part of PR bin/53513.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/tre/dist/src/agrep.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/tre/dist/src/agrep.c
diff -u src/external/bsd/tre/dist/src/agrep.c:1.5 src/external/bsd/tre/dist/src/agrep.c:1.6
--- src/external/bsd/tre/dist/src/agrep.c:1.5	Thu May 23 22:07:16 2024
+++ src/external/bsd/tre/dist/src/agrep.c	Fri May 24 07:52:45 2024
@@ -320,10 +320,6 @@ tre_agrep_get_next_record(int fd, const 
 }
 }
 
-#include 
-#include 
-#include 
-
 #include 
 
 static int tre_agrep_handle_file(const char */*filename*/);



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

2024-05-24 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Fri May 24 07:52:46 UTC 2024

Modified Files:
src/external/bsd/tre/dist/src: agrep.c

Log Message:
agrep(1): remove duplicated and obsolete imports.

dirent import is the only one which stays in the odd location.

Part of PR bin/53513.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/tre/dist/src/agrep.c

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



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

2024-05-23 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Thu May 23 22:07:16 UTC 2024

Modified Files:
src/external/bsd/tre/dist/src: agrep.c

Log Message:
agrep(1): rewrite binary check introduced with recursive search on rev 1.3 to
match more closely grep(1) implementation. Instead of opening and scanning
full file every time, check for the \0 symbol once the file buffer is filled up
for the first time.

Patch fixes stdin, adds binary check for it as well, and works more efficiently
(at the cost of not scanning the full file).

Also original implementation forgot to add break if binary file is detected,
causing duplicate binary matches in the output result.

Due to full file scans on each match instead of once for the specific file,
scans may have been considerably slow.

Fixes PR bin/53513

Needs pullups to netbsd-9,-10.

Thanks for the help from mlelstv and dh in reviewing and finalizing the patch.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/tre/dist/src/agrep.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/tre/dist/src/agrep.c
diff -u src/external/bsd/tre/dist/src/agrep.c:1.4 src/external/bsd/tre/dist/src/agrep.c:1.5
--- src/external/bsd/tre/dist/src/agrep.c:1.4	Thu Aug 20 15:54:11 2020
+++ src/external/bsd/tre/dist/src/agrep.c	Thu May 23 22:07:16 2024
@@ -179,6 +179,7 @@ static int next_delim_len; /* Length of 
 static int delim_after = 1;/* If true, print the delimiter after the record. */
 static int at_eof;
 static int have_matches;   /* If true, matches have been found. */
+static int is_binary;  /* -1 unknown, 0 ascii, 1 binary */
 
 static int invert_match;   /* Show only non-matching records. */
 static int print_filename; /* Output filename. */
@@ -200,6 +201,12 @@ static regaparams_t match_params;
environment variable GREP_COLOR overrides this default value. */
 static const char *highlight = "01;31";
 
+static int
+isbinaryfile(void)
+{
+	return buf != NULL && memchr(buf, '\0', data_len) != NULL;
+}
+
 /* Sets `record' to the next complete record from file `fd', and `record_len'
to the length of the record.	 Returns 1 when there are no more records,
0 otherwise. */
@@ -262,6 +269,9 @@ tre_agrep_get_next_record(int fd, const 
 	}
 	  data_len += r;
 	  next_record = buf;
+
+	  if (is_binary < 0)
+	is_binary = isbinaryfile();
 	}
 
   /* Find the next record delimiter. */
@@ -316,41 +326,6 @@ tre_agrep_get_next_record(int fd, const 
 
 #include 
 
-static int
-isbinaryfile(const char *filename)
-{
-	struct stat	 st;
-	size_t		 size;
-	size_t		 i;
-	char		*mapped;
-	FILE		*fp;
-	int		 isbin;
-
-	if ((fp = fopen(filename, "r")) == NULL) {
-		return 1;
-	}
-	fstat(fileno(fp), );
-	isbin = 0;
-	if ((st.st_mode & S_IFMT) != S_IFREG) {
-		isbin = 1;
-	} else {
-		size = (size_t)st.st_size;
-		mapped = mmap(NULL, size, PROT_READ, MAP_SHARED, fileno(fp), 0);
-		if (mapped == MAP_FAILED) {
-			fclose(fp);
-			return 1;
-		}
-		for (i = 0 ; !isbin && i < size ; i++) {
-			if (mapped[i] == 0x0) {
-isbin = 1;
-			}
-		}
-		munmap(mapped, size);
-	}
-	fclose(fp);
-	return isbin;
-}
-
 static int tre_agrep_handle_file(const char */*filename*/);
 
 static int
@@ -398,6 +373,8 @@ tre_agrep_handle_file(const char *filena
   int count = 0;
   int recnum = 0;
 
+  is_binary = -1;
+
   /* Allocate the initial buffer. */
   if (buf == NULL)
 {
@@ -488,10 +465,12 @@ tre_agrep_handle_file(const char *filena
 	  printf("%s\n", filename);
 	  break;
 	}
-	  else if (!count_matches && isbinaryfile(filename))
+	  else if (!count_matches && is_binary > 0)
 	{
 	  if (print_filename)
-		printf("Binary file %s matches\n", filename);
+		printf("%s:", filename);
+	  printf("Binary file matches\n");
+	  break;
 	}
 	  else if (!count_matches)
 	{



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

2024-05-23 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Thu May 23 22:07:16 UTC 2024

Modified Files:
src/external/bsd/tre/dist/src: agrep.c

Log Message:
agrep(1): rewrite binary check introduced with recursive search on rev 1.3 to
match more closely grep(1) implementation. Instead of opening and scanning
full file every time, check for the \0 symbol once the file buffer is filled up
for the first time.

Patch fixes stdin, adds binary check for it as well, and works more efficiently
(at the cost of not scanning the full file).

Also original implementation forgot to add break if binary file is detected,
causing duplicate binary matches in the output result.

Due to full file scans on each match instead of once for the specific file,
scans may have been considerably slow.

Fixes PR bin/53513

Needs pullups to netbsd-9,-10.

Thanks for the help from mlelstv and dh in reviewing and finalizing the patch.


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

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



CVS commit: src/external/bsd/nvi/dist/docs/vi.man

2024-04-28 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Mon Apr 29 00:50:43 UTC 2024

Modified Files:
src/external/bsd/nvi/dist/docs/vi.man: vi.1

Log Message:
Remove documentation for long removed -F option

Suggested by Robert Whitlock in PR bin/58177

I've sent this patch to the nvi maintainers but the response suggested
patching this downstream, as there would be no further releases of nvi.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/nvi/dist/docs/vi.man/vi.1

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/nvi/dist/docs/vi.man/vi.1
diff -u src/external/bsd/nvi/dist/docs/vi.man/vi.1:1.7 src/external/bsd/nvi/dist/docs/vi.man/vi.1:1.8
--- src/external/bsd/nvi/dist/docs/vi.man/vi.1:1.7	Fri Sep 14 13:19:15 2018
+++ src/external/bsd/nvi/dist/docs/vi.man/vi.1	Mon Apr 29 00:50:42 2024
@@ -1,4 +1,4 @@
-.\"	$NetBSD: vi.1,v 1.7 2018/09/14 13:19:15 rin Exp $
+.\"	$NetBSD: vi.1,v 1.8 2024/04/29 00:50:42 maya Exp $
 .\"
 .\" Copyright (c) 1994
 .\" The Regents of the University of California.  All rights reserved.
@@ -12,14 +12,14 @@
 .\"
 .\" Id: vi.1,v 8.53 2001/01/28 13:20:06 skimo Exp  (Berkeley) Date: 2001/01/28 13:20:06 
 .\"
-.TH VI 1 "September 14, 2018"
+.TH VI 1 "April 28, 2024"
 .UC
 .SH NAME
 ex, vi, view \- text editors
 .SH SYNOPSIS
 .B ex
 [\c
-.B -eFGRrSsv\c
+.B -eGRrSsv\c
 ] [\c
 .BI -c " cmd"\c
 ] [\c
@@ -30,7 +30,7 @@ ex, vi, view \- text editors
 .br
 .B vi
 [\c
-.B -eFlRrSv\c
+.B -elRrSv\c
 ] [\c
 .BI -c " cmd"\c
 ] [\c
@@ -41,7 +41,7 @@ ex, vi, view \- text editors
 .br
 .B view
 [\c
-.B -eFGRrSv\c
+.B -eGRrSv\c
 ] [\c
 .BI -c " cmd"\c
 ] [\c
@@ -115,11 +115,6 @@ supports both the old and new syntax.
 Start editing in ex mode, as if the command name were
 .IR \ .
 .TP
-.B \-F
-Don't copy the entire file when first starting to edit.
-(The default is to make a copy in case someone else modifies
-the file during your edit session.)
-.TP
 .B \-G
 Start editing in gtags mode, as if the gtagsmode option was set.
 .TP



CVS commit: src/external/bsd/nvi/dist/docs/vi.man

2024-04-28 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Mon Apr 29 00:50:43 UTC 2024

Modified Files:
src/external/bsd/nvi/dist/docs/vi.man: vi.1

Log Message:
Remove documentation for long removed -F option

Suggested by Robert Whitlock in PR bin/58177

I've sent this patch to the nvi maintainers but the response suggested
patching this downstream, as there would be no further releases of nvi.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/nvi/dist/docs/vi.man/vi.1

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Sun Apr 21 17:19:52 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
libntf: make MKREPRO timestamp compatible with NetBSD 10

In NetBSD 10, make(1) cannot handle :gmtime arguments that are
expressions, resulting in the error message "Unknown modifier '1'".


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Sun Apr 21 17:19:52 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
libntf: make MKREPRO timestamp compatible with NetBSD 10

In NetBSD 10, make(1) cannot handle :gmtime arguments that are
expressions, resulting in the error message "Unknown modifier '1'".


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.35 src/external/bsd/ntp/lib/libntp/Makefile:1.36
--- src/external/bsd/ntp/lib/libntp/Makefile:1.35	Sat Apr 20 08:03:08 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Sun Apr 21 17:19:52 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.35 2024/04/20 08:03:08 rillig Exp $
+#	$NetBSD: Makefile,v 1.36 2024/04/21 17:19:52 rillig Exp $
 
 LIBISPRIVATE=yes
 
@@ -88,8 +88,8 @@ CPPFLAGS+= -I${IDIST}/sntp/libopts
 # For MKREPRO, avoid using __DATE__ and __TIME__.
 .if ${MKREPRO:Uno} == "yes"
 MKREPRO_CPPFLAGS.ntp_calendar.c:= \
-	-DMKREPRO_DATE=\"${%b %e %Y:L:gmtime=${MKREPRO_TIMESTAMP}:Q}\" \
-	-DMKREPRO_TIME=\"${%T:L:gmtime=${MKREPRO_TIMESTAMP}:Q}\"
+	-DMKREPRO_DATE=\"${%b %e %Y:L:${:Ugmtime=${MKREPRO_TIMESTAMP}}:Q}\" \
+	-DMKREPRO_TIME=\"${%T:L:${:Ugmtime=${MKREPRO_TIMESTAMP}}:Q}\"
 CPPFLAGS.ntp_calendar.c += ${MKREPRO_CPPFLAGS.ntp_calendar.c}
 .endif
 



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-20 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Sat Apr 20 08:03:08 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
libntp: clean up MKREPRO_TIMESTAMP handling

NetBSD's make has built-in support for formatting timestamps, so use
that instead of relying on an external tool.  The month name is still
always in the C locale, and possible errors are reported in the affected
line, due to the ':=' assignment operator.

Without the ':=' assignment operator, the intermediate variable would
not be necessary, but in that case, make's error handling is broken and
unspecific.


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-20 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Sat Apr 20 08:03:08 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
libntp: clean up MKREPRO_TIMESTAMP handling

NetBSD's make has built-in support for formatting timestamps, so use
that instead of relying on an external tool.  The month name is still
always in the C locale, and possible errors are reported in the affected
line, due to the ':=' assignment operator.

Without the ':=' assignment operator, the intermediate variable would
not be necessary, but in that case, make's error handling is broken and
unspecific.


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.34 src/external/bsd/ntp/lib/libntp/Makefile:1.35
--- src/external/bsd/ntp/lib/libntp/Makefile:1.34	Fri Apr 19 16:04:28 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Sat Apr 20 08:03:08 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.34 2024/04/19 16:04:28 jakllsch Exp $
+#	$NetBSD: Makefile,v 1.35 2024/04/20 08:03:08 rillig Exp $
 
 LIBISPRIVATE=yes
 
@@ -86,18 +86,11 @@ ymd2yd.c
 CPPFLAGS+= -I${IDIST}/sntp/libopts
 
 # For MKREPRO, avoid using __DATE__ and __TIME__.
-# Instead, use the date and time from ${MKREPRO_TIMESTAMP}
 .if ${MKREPRO:Uno} == "yes"
-.if ${MKREPRO_TIMESTAMP:Uundefined} == "undefined"
-.error MKREPRO_TIMESTAMP is undefined with MKREPRO active
-.endif
-MKREPRO_DATE != env LC_ALL=C ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %e %Y"
-MKREPRO_TIME != env LC_ALL=C ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
-.if ${MKREPRO_DATE} == "" || ${MKREPRO_TIME} == ""
-.error empty MKREPRO_DATE or MKREPRO_TIME
-.endif
-CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"
-CPPFLAGS.ntp_calendar.c += -DMKREPRO_TIME=\"${MKREPRO_TIME:Q}\"
+MKREPRO_CPPFLAGS.ntp_calendar.c:= \
+	-DMKREPRO_DATE=\"${%b %e %Y:L:gmtime=${MKREPRO_TIMESTAMP}:Q}\" \
+	-DMKREPRO_TIME=\"${%T:L:gmtime=${MKREPRO_TIMESTAMP}:Q}\"
+CPPFLAGS.ntp_calendar.c += ${MKREPRO_CPPFLAGS.ntp_calendar.c}
 .endif
 
 COPTS.timetoa.c+=	${CC_WNO_FORMAT_TRUNCATION}



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 19 16:04:28 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
fix copy/paste-o


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 19 16:04:28 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
fix copy/paste-o


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.33 src/external/bsd/ntp/lib/libntp/Makefile:1.34
--- src/external/bsd/ntp/lib/libntp/Makefile:1.33	Fri Apr 19 14:58:18 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Fri Apr 19 16:04:28 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.33 2024/04/19 14:58:18 jakllsch Exp $
+#	$NetBSD: Makefile,v 1.34 2024/04/19 16:04:28 jakllsch Exp $
 
 LIBISPRIVATE=yes
 
@@ -93,7 +93,7 @@ CPPFLAGS+= -I${IDIST}/sntp/libopts
 .endif
 MKREPRO_DATE != env LC_ALL=C ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %e %Y"
 MKREPRO_TIME != env LC_ALL=C ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
-.if ${MKREPRO_TIME} == "" || ${MKREPRO_TIME} == ""
+.if ${MKREPRO_DATE} == "" || ${MKREPRO_TIME} == ""
 .error empty MKREPRO_DATE or MKREPRO_TIME
 .endif
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"



Re: CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Jonathan A. Kollasch
On Fri, Apr 19, 2024 at 10:48:10PM +0700, Robert Elz wrote:
> Date:Fri, 19 Apr 2024 14:58:18 +
> From:"Jonathan A. Kollasch" 
> Message-ID:  <20240419145818.351d2f...@cvs.netbsd.org>
> 
>   |  - bail out if resulting __DATE__/__TIME__ replacement strings are empty
> 
> If you want to do that (not that it would be useful, even if the %b
> (etc) conversions produced nothing, there would still be two spaces
> in the output.   It is almost impossible to get date to exit with an
> error code (and nothing on stdout) in cases like this.
> 
> But if this is worth keeping, then
> 
>   if ${MKREPRO_TIME} == "" || ${MKREPRO_TIME} == ""
> 
> probably is not what you wanted.

I've tested this with MKREPRO_TIMESTAMP=RandomNonNumericString, and
MKREPRO_TIME/MKREPRO_DATE came out "" when nbdate produced a non-zero
exit status and a warning message.

I wish nbmake could actually error when it gets a non-zero exit status
there, but it merely spouts a warning and continues.

I've spent enough time looking at this.


Re: CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Robert Elz
Date:Fri, 19 Apr 2024 14:58:18 +
From:"Jonathan A. Kollasch" 
Message-ID:  <20240419145818.351d2f...@cvs.netbsd.org>

  |  - bail out if resulting __DATE__/__TIME__ replacement strings are empty

If you want to do that (not that it would be useful, even if the %b
(etc) conversions produced nothing, there would still be two spaces
in the output.   It is almost impossible to get date to exit with an
error code (and nothing on stdout) in cases like this.

But if this is worth keeping, then

if ${MKREPRO_TIME} == "" || ${MKREPRO_TIME} == ""

probably is not what you wanted.

kre



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 19 14:58:18 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
Increase MKREPRO robustness
 - Use C locale to ensure month abbreviations are as expected
 - bail out if MKREPRO_TIMESTAMP is not defined
 - bail out if resulting __DATE__/__TIME__ replacement strings are empty


To generate a diff of this commit:
cvs rdiff -u -r1.32 -r1.33 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 19 14:58:18 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
Increase MKREPRO robustness
 - Use C locale to ensure month abbreviations are as expected
 - bail out if MKREPRO_TIMESTAMP is not defined
 - bail out if resulting __DATE__/__TIME__ replacement strings are empty


To generate a diff of this commit:
cvs rdiff -u -r1.32 -r1.33 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.32 src/external/bsd/ntp/lib/libntp/Makefile:1.33
--- src/external/bsd/ntp/lib/libntp/Makefile:1.32	Fri Apr 19 13:34:15 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Fri Apr 19 14:58:18 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.32 2024/04/19 13:34:15 jakllsch Exp $
+#	$NetBSD: Makefile,v 1.33 2024/04/19 14:58:18 jakllsch Exp $
 
 LIBISPRIVATE=yes
 
@@ -88,8 +88,14 @@ CPPFLAGS+= -I${IDIST}/sntp/libopts
 # For MKREPRO, avoid using __DATE__ and __TIME__.
 # Instead, use the date and time from ${MKREPRO_TIMESTAMP}
 .if ${MKREPRO:Uno} == "yes"
-MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %e %Y"
-MKREPRO_TIME != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
+.if ${MKREPRO_TIMESTAMP:Uundefined} == "undefined"
+.error MKREPRO_TIMESTAMP is undefined with MKREPRO active
+.endif
+MKREPRO_DATE != env LC_ALL=C ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %e %Y"
+MKREPRO_TIME != env LC_ALL=C ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
+.if ${MKREPRO_TIME} == "" || ${MKREPRO_TIME} == ""
+.error empty MKREPRO_DATE or MKREPRO_TIME
+.endif
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_TIME=\"${MKREPRO_TIME:Q}\"
 .endif



Re: CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Rhialto
On Fri 19 Apr 2024 at 14:47:23 +0200, Martin Husemann wrote:
> The problem (IIUC) is that the ntp code parses this value internally, so
> it won't talk to anyone claiming a time before the time ntpd was compiled
> (or something along that line).

Would it make sense to just supply a fixed string to effectively defang
that code? Or just rip it out completely. It sounds like a giant footgun
somehow.

-Olaf.
-- 
___ Olaf 'Rhialto' Seibert
\X/ There is no AI. There is just someone else's work.   --I. Rose


signature.asc
Description: PGP signature


Re: CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Robert Elz
Date:Fri, 19 Apr 2024 14:57:46 +0200
From:Martin Husemann 
Message-ID:  <20240419125746.gb26...@mail.duskware.de>

  | On Fri, Apr 19, 2024 at 02:47:23PM +0200, Martin Husemann wrote:
  | > The commit message could have explained that a bit.
  |
  | And it actually should have been "+%b %e %Y" - from the C18 standard draft:
  |
  | 6.10.8.1 Mandatory macros
  |
  | __DATE__ 
  |
  | The date of translation of the preprocessing translation unit: a
  | character string literal of the form "Mmm dd ", where the names of
  | the months are the same as those generated by the asctime function,

If that's still in the most recent C (in that form anyway) I'd be surprised,
as asctime() is more or less deprecated I think.

But if that is what is required, then the TOOL_DATE needs to be run with
LC_ALL=C (or LC_ALL=POSIX) so that you get the month name in English, rather
than whatever the local locale's short name for the month would be.

It is still a stupid format...

kre



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 19 13:34:15 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
The substitute __DATE__ should be %b %e %Y per a C18 draft

Subtle change that won't make a functional difference in this case;
changed only for semantic correctness.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 19 13:34:15 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
The substitute __DATE__ should be %b %e %Y per a C18 draft

Subtle change that won't make a functional difference in this case;
changed only for semantic correctness.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.31 src/external/bsd/ntp/lib/libntp/Makefile:1.32
--- src/external/bsd/ntp/lib/libntp/Makefile:1.31	Thu Apr 18 19:23:53 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Fri Apr 19 13:34:15 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.31 2024/04/18 19:23:53 jakllsch Exp $
+#	$NetBSD: Makefile,v 1.32 2024/04/19 13:34:15 jakllsch Exp $
 
 LIBISPRIVATE=yes
 
@@ -88,7 +88,7 @@ CPPFLAGS+= -I${IDIST}/sntp/libopts
 # For MKREPRO, avoid using __DATE__ and __TIME__.
 # Instead, use the date and time from ${MKREPRO_TIMESTAMP}
 .if ${MKREPRO:Uno} == "yes"
-MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %d %Y"
+MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %e %Y"
 MKREPRO_TIME != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_TIME=\"${MKREPRO_TIME:Q}\"



Re: CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Martin Husemann
On Fri, Apr 19, 2024 at 02:47:23PM +0200, Martin Husemann wrote:
> The commit message could have explained that a bit.

And it actually should have been "+%b %e %Y" - from the C18 standard draft:

6.10.8.1 Mandatory macros

__DATE__ 

The date of translation of the preprocessing translation unit: a
character string literal of the form "Mmm dd ", where the names of
the months are the same as those generated by the asctime function, and
the first character of dd is a space character if the value is less
than 10. If the date of translation is not available, an
implementation-defined valid date shall be supplied.


Martin


Re: CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Martin Husemann
On Fri, Apr 19, 2024 at 04:36:46PM +0700, Robert Elz wrote:
> I don't understand that change, it altered from
> 
>   MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%F"
> to
>   MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %d %Y"
> 
> %F is simply a shorthand for %Y-%m-%d (which is the correct way to write
> locale independent dates), %b is a locale dependent name of the month, and
> what's more this is in US-centric mon day year format, which we should avoid
> (aside from anything else, it is a dumb format, with the smallest value unit
> sitting in the middle, rather than at one end or the other).

The problem (IIUC) is that the ntp code parses this value internally, so
it won't talk to anyone claiming a time before the time ntpd was compiled
(or something along that line).

And __DATE__ gives us a stupid format: 

 > echo __DATE__ | cc -E - | tail -1
"Apr 19 2024"

which is different from

 > date -u -r 1713530399 "+%F"
2024-04-19

but matches

> date -u -r 1713530399 "+%b %d %Y"
Apr 19 2024


The commit message could have explained that a bit.

Martin


Re: CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-19 Thread Robert Elz
Date:Thu, 18 Apr 2024 19:23:54 +
From:"Jonathan A. Kollasch" 
Message-ID:  <20240418192354.1bcc1f...@cvs.netbsd.org>

  | Module Name:src
  | Committed By:   jakllsch
  | Date:   Thu Apr 18 19:23:54 UTC 2024
  |
  | Modified Files:
  | src/external/bsd/ntp/lib/libntp: Makefile
  |
  | Log Message:
  | Format MKREPRO_TIMESTAMP with "%b %d %Y" to correctly substitute __DATE__

I don't understand that change, it altered from

MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%F"
to
MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %d %Y"

%F is simply a shorthand for %Y-%m-%d (which is the correct way to write
locale independent dates), %b is a locale dependent name of the month, and
what's more this is in US-centric mon day year format, which we should avoid
(aside from anything else, it is a dumb format, with the smallest value unit
sitting in the middle, rather than at one end or the other).

If there is a problem where support for %F is missing somewhere, (and if
that happens in TOOL_DATE it must mean that we're using a locale strftime()
when building it, in which case we should add our version to the library)
please replace it with %Y-%m-%d (which is what it is defined to be) instead
of anything using %b (or %a or %B or %A) (or any other weird formats).

Further, if some format like that was needed for some reason, then it
probably should use %e rather than %d (to suppress the leading 0 on dates
before the 10th).   But don't just do that either.

If there isn't an actual problem using %F, please just revert this.

And lastly, and this applies to everyone - please do not request
pullups of anything (except perhaps urgent security fixes) immediately
after the change is committed - give it at least a few days, in case of
objection, breakage, ...

kre




CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-18 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu Apr 18 19:23:54 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
Format MKREPRO_TIMESTAMP with "%b %d %Y" to correctly substitute __DATE__


To generate a diff of this commit:
cvs rdiff -u -r1.30 -r1.31 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.30 src/external/bsd/ntp/lib/libntp/Makefile:1.31
--- src/external/bsd/ntp/lib/libntp/Makefile:1.30	Fri Apr 12 19:06:45 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Thu Apr 18 19:23:53 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.30 2024/04/12 19:06:45 jakllsch Exp $
+#	$NetBSD: Makefile,v 1.31 2024/04/18 19:23:53 jakllsch Exp $
 
 LIBISPRIVATE=yes
 
@@ -88,7 +88,7 @@ CPPFLAGS+= -I${IDIST}/sntp/libopts
 # For MKREPRO, avoid using __DATE__ and __TIME__.
 # Instead, use the date and time from ${MKREPRO_TIMESTAMP}
 .if ${MKREPRO:Uno} == "yes"
-MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%F"
+MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%b %d %Y"
 MKREPRO_TIME != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_TIME=\"${MKREPRO_TIME:Q}\"



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-18 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu Apr 18 19:23:54 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
Format MKREPRO_TIMESTAMP with "%b %d %Y" to correctly substitute __DATE__


To generate a diff of this commit:
cvs rdiff -u -r1.30 -r1.31 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-12 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 12 19:06:45 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
remove now-unused assignment


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.29 src/external/bsd/ntp/lib/libntp/Makefile:1.30
--- src/external/bsd/ntp/lib/libntp/Makefile:1.29	Wed Apr  3 00:38:36 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Fri Apr 12 19:06:45 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.29 2024/04/03 00:38:36 christos Exp $
+#	$NetBSD: Makefile,v 1.30 2024/04/12 19:06:45 jakllsch Exp $
 
 LIBISPRIVATE=yes
 
@@ -88,7 +88,6 @@ CPPFLAGS+= -I${IDIST}/sntp/libopts
 # For MKREPRO, avoid using __DATE__ and __TIME__.
 # Instead, use the date and time from ${MKREPRO_TIMESTAMP}
 .if ${MKREPRO:Uno} == "yes"
-IMPORTDATE_FILE := ${.PARSEDIR}/../../importdate
 MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%F"
 MKREPRO_TIME != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-12 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Apr 12 19:06:45 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
remove now-unused assignment


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/external/bsd/ntp/lib/libntp/Makefile

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



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

2024-04-05 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Fri Apr  5 22:21:40 UTC 2024

Modified Files:
src/external/bsd/flex/bin: flex.1

Log Message:
flex.1: fix single-bit error in contributor name


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/flex/bin/flex.1

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/bin/flex.1
diff -u src/external/bsd/flex/bin/flex.1:1.5 src/external/bsd/flex/bin/flex.1:1.6
--- src/external/bsd/flex/bin/flex.1:1.5	Sun Aug 28 10:48:16 2022
+++ src/external/bsd/flex/bin/flex.1	Fri Apr  5 22:21:40 2024
@@ -1,4 +1,4 @@
-.\" $NetBSD: flex.1,v 1.5 2022/08/28 10:48:16 hgutch Exp $
+.\" $NetBSD: flex.1,v 1.6 2024/04/05 22:21:40 rillig Exp $
 .\"
 .TH FLEX 1 "December 2021" "Version 2.5"
 .SH NAME
@@ -4266,7 +4266,7 @@ Frederic Raimbault, Pat Rankin, Rick Ric
 Kevin Rodgers, Kai Uwe Rommel, Jim Roskind, Alberto Santini,
 Andreas Scherer, Darrell Schiebel, Raf Schietekat,
 Doug Schmidt, Philippe Schnoebelen, Andreas Schwab,
-Larry Schwimmer, Alex Siegel, Eckehard Stolz, Jan-Erik Strvmquist,
+Larry Schwimmer, Alex Siegel, Eckehard Stolz, Jan-Erik Str\[:o]mquist,
 Mike Stump, Paul Stuart, Dave Tallman, Ian Lance Taylor,
 Chris Thewalt, Richard M. Timoney, Jodi Tsai,
 Paul Tuinenga, Gary Weik, Frank Whaley, Gerhard Wilhelms, Kent Williams, Ken



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

2024-04-05 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Fri Apr  5 22:21:40 UTC 2024

Modified Files:
src/external/bsd/flex/bin: flex.1

Log Message:
flex.1: fix single-bit error in contributor name


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/flex/bin/flex.1

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



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

2024-04-05 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Apr  5 16:56:58 UTC 2024

Modified Files:
src/external/bsd/file/dist/src: apprentice.c

Log Message:
break strength ties so that qsort is deterministic


To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/external/bsd/file/dist/src/apprentice.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/file/dist/src/apprentice.c
diff -u src/external/bsd/file/dist/src/apprentice.c:1.28 src/external/bsd/file/dist/src/apprentice.c:1.29
--- src/external/bsd/file/dist/src/apprentice.c:1.28	Fri Aug 18 15:00:11 2023
+++ src/external/bsd/file/dist/src/apprentice.c	Fri Apr  5 12:56:58 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: apprentice.c,v 1.28 2023/08/18 19:00:11 christos Exp $	*/
+/*	$NetBSD: apprentice.c,v 1.29 2024/04/05 16:56:58 christos Exp $	*/
 
 /*
  * Copyright (c) Ian F. Darwin 1986-1995.
@@ -37,7 +37,7 @@
 #if 0
 FILE_RCSID("@(#)$File: apprentice.c,v 1.342 2023/07/17 14:38:35 christos Exp $")
 #else
-__RCSID("$NetBSD: apprentice.c,v 1.28 2023/08/18 19:00:11 christos Exp $");
+__RCSID("$NetBSD: apprentice.c,v 1.29 2024/04/05 16:56:58 christos Exp $");
 #endif
 #endif	/* lint */
 
@@ -1141,8 +1141,12 @@ apprentice_sort(const void *a, const voi
 	const struct magic_entry *mb = CAST(const struct magic_entry *, b);
 	size_t sa = file_magic_strength(ma->mp, ma->cont_count);
 	size_t sb = file_magic_strength(mb->mp, mb->cont_count);
-	if (sa == sb)
-		return 0;
+	if (sa == sb) {
+		int x = memcmp(ma->mp, mb->mp, sizeof(*ma->mp));
+		if (x == 0)
+			abort();
+		return x > 0 ? -1 : 1;
+	}
 	else if (sa > sb)
 		return -1;
 	else



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

2024-04-05 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Apr  5 16:56:58 UTC 2024

Modified Files:
src/external/bsd/file/dist/src: apprentice.c

Log Message:
break strength ties so that qsort is deterministic


To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/external/bsd/file/dist/src/apprentice.c

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



CVS commit: src/external/bsd/am-utils/dist

2024-04-04 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Apr  4 20:33:59 UTC 2024

Removed Files:
src/external/bsd/am-utils/dist: amd2netbsd

Log Message:
external/bsd/am-utils: delete outdated amd2netbsd under dist

This was stored as a local change to dist, where it doesn't belong --
it belongs outside dist.  But we already have an amd2netbsd with the
correct path outside of dist.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r0 src/external/bsd/am-utils/dist/amd2netbsd

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



CVS commit: src/external/bsd/am-utils/dist

2024-04-04 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Apr  4 20:33:59 UTC 2024

Removed Files:
src/external/bsd/am-utils/dist: amd2netbsd

Log Message:
external/bsd/am-utils: delete outdated amd2netbsd under dist

This was stored as a local change to dist, where it doesn't belong --
it belongs outside dist.  But we already have an amd2netbsd with the
correct path outside of dist.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r0 src/external/bsd/am-utils/dist/amd2netbsd

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 00:38:36 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
fix format.


To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.28 src/external/bsd/ntp/lib/libntp/Makefile:1.29
--- src/external/bsd/ntp/lib/libntp/Makefile:1.28	Tue Apr  2 10:19:02 2024
+++ src/external/bsd/ntp/lib/libntp/Makefile	Tue Apr  2 20:38:36 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.28 2024/04/02 14:19:02 christos Exp $
+#	$NetBSD: Makefile,v 1.29 2024/04/03 00:38:36 christos Exp $
 
 LIBISPRIVATE=yes
 
@@ -89,8 +89,8 @@ CPPFLAGS+= -I${IDIST}/sntp/libopts
 # Instead, use the date and time from ${MKREPRO_TIMESTAMP}
 .if ${MKREPRO:Uno} == "yes"
 IMPORTDATE_FILE := ${.PARSEDIR}/../../importdate
-MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "%F"
-MKREPRO_TIME != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "%T"
+MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%F"
+MKREPRO_TIME != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "+%T"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_TIME=\"${MKREPRO_TIME:Q}\"
 .endif



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 00:38:36 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
fix format.


To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Apr  2 14:19:02 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
use ${MKREPRO_TIMESTAMP} for baking in the date and time.


To generate a diff of this commit:
cvs rdiff -u -r1.27 -r1.28 src/external/bsd/ntp/lib/libntp/Makefile

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



CVS commit: src/external/bsd/ntp/lib/libntp

2024-04-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Apr  2 14:19:02 UTC 2024

Modified Files:
src/external/bsd/ntp/lib/libntp: Makefile

Log Message:
use ${MKREPRO_TIMESTAMP} for baking in the date and time.


To generate a diff of this commit:
cvs rdiff -u -r1.27 -r1.28 src/external/bsd/ntp/lib/libntp/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/bsd/ntp/lib/libntp/Makefile
diff -u src/external/bsd/ntp/lib/libntp/Makefile:1.27 src/external/bsd/ntp/lib/libntp/Makefile:1.28
--- src/external/bsd/ntp/lib/libntp/Makefile:1.27	Sat Jun  3 05:09:04 2023
+++ src/external/bsd/ntp/lib/libntp/Makefile	Tue Apr  2 10:19:02 2024
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.27 2023/06/03 09:09:04 lukem Exp $
+#	$NetBSD: Makefile,v 1.28 2024/04/02 14:19:02 christos Exp $
 
 LIBISPRIVATE=yes
 
@@ -86,17 +86,11 @@ ymd2yd.c
 CPPFLAGS+= -I${IDIST}/sntp/libopts
 
 # For MKREPRO, avoid using __DATE__ and __TIME__.
-# Instead, use the date and time from ${IMPORTDATE_FILE}.
-#
-# The file should contain one line, like this:
-#	Fri Dec 27 19:28:17 EST 2013 (import)
-#
+# Instead, use the date and time from ${MKREPRO_TIMESTAMP}
 .if ${MKREPRO:Uno} == "yes"
 IMPORTDATE_FILE := ${.PARSEDIR}/../../importdate
-MKREPRO_DATE != ${TOOL_AWK} '{printf "%3s %2d %4d", $$2, $$3, $$6}' \
-	<${IMPORTDATE_FILE} # "Mmm DD "
-MKREPRO_TIME != ${TOOL_AWK} '{print $$4}' \
-	<${IMPORTDATE_FILE} # "HH:MM:SS"
+MKREPRO_DATE != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "%F"
+MKREPRO_TIME != ${TOOL_DATE} -u -r "${MKREPRO_TIMESTAMP}" "%T"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_DATE=\"${MKREPRO_DATE:Q}\"
 CPPFLAGS.ntp_calendar.c += -DMKREPRO_TIME=\"${MKREPRO_TIME:Q}\"
 .endif



CVS commit: src/external/bsd/elftoolchain/common/sys

2024-03-27 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Mar 27 21:55:35 UTC 2024

Modified Files:
src/external/bsd/elftoolchain/common/sys: Makefile

Log Message:
Add ${_MKTARGET_CREATE}


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/external/bsd/elftoolchain/common/sys/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/bsd/elftoolchain/common/sys/Makefile
diff -u src/external/bsd/elftoolchain/common/sys/Makefile:1.1 src/external/bsd/elftoolchain/common/sys/Makefile:1.2
--- src/external/bsd/elftoolchain/common/sys/Makefile:1.1	Tue Apr  6 15:40:19 2021
+++ src/external/bsd/elftoolchain/common/sys/Makefile	Wed Mar 27 17:55:35 2024
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2021/04/06 19:40:19 jkoshy Exp $
+# $NetBSD: Makefile,v 1.2 2024/03/27 21:55:35 christos Exp $
 
 .include 
 
@@ -11,6 +11,7 @@ INCS=		elfdefinitions.h
 INCSDIR=	/usr/include/sys
 
 elfdefinitions.h:	elfdefinitions.m4 elfconstants.m4
+	${_MKTARGET_CREATE}
 	${TOOL_M4} -I${SRCDIR} -D SRCDIR=${SRCDIR} ${M4FLAGS} \
 		elfdefinitions.m4 > ${.TARGET}
 



CVS commit: src/external/bsd/elftoolchain/common/sys

2024-03-27 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Mar 27 21:55:35 UTC 2024

Modified Files:
src/external/bsd/elftoolchain/common/sys: Makefile

Log Message:
Add ${_MKTARGET_CREATE}


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/external/bsd/elftoolchain/common/sys/Makefile

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



CVS commit: src/external/bsd/elftoolchain/dist/libdwarf

2024-03-27 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Mar 27 21:53:06 UTC 2024

Modified Files:
src/external/bsd/elftoolchain/dist/libdwarf: libdwarf_reloc.c

Log Message:
Don't try to compile the arch-specific relocation code if we don't have the
built-in headers (for tools)


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/bsd/elftoolchain/dist/libdwarf/libdwarf_reloc.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/elftoolchain/dist/libdwarf/libdwarf_reloc.c
diff -u src/external/bsd/elftoolchain/dist/libdwarf/libdwarf_reloc.c:1.5 src/external/bsd/elftoolchain/dist/libdwarf/libdwarf_reloc.c:1.6
--- src/external/bsd/elftoolchain/dist/libdwarf/libdwarf_reloc.c:1.5	Sun Mar  3 12:37:32 2024
+++ src/external/bsd/elftoolchain/dist/libdwarf/libdwarf_reloc.c	Wed Mar 27 17:53:06 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: libdwarf_reloc.c,v 1.5 2024/03/03 17:37:32 christos Exp $	*/
+/*	$NetBSD: libdwarf_reloc.c,v 1.6 2024/03/27 21:53:06 christos Exp $	*/
 
 /*-
  * Copyright (c) 2010 Kai Wang
@@ -28,7 +28,7 @@
 
 #include "_libdwarf.h"
 
-__RCSID("$NetBSD: libdwarf_reloc.c,v 1.5 2024/03/03 17:37:32 christos Exp $");
+__RCSID("$NetBSD: libdwarf_reloc.c,v 1.6 2024/03/27 21:53:06 christos Exp $");
 ELFTC_VCSID("Id: libdwarf_reloc.c 3741 2019-06-07 06:32:01Z jkoshy");
 
 Dwarf_Unsigned
@@ -36,7 +36,7 @@ _dwarf_get_reloc_type(Dwarf_P_Debug dbg,
 {
 
 	assert(dbg != NULL);
-
+#ifdef BUILTIN_ELF_HEADERS
 	switch (dbg->dbgp_isa) {
 	case DW_ISA_AARCH64:
 		return (is64 ? R_AARCH64_ABS64 : R_AARCH64_ABS32);
@@ -59,6 +59,7 @@ _dwarf_get_reloc_type(Dwarf_P_Debug dbg,
 	default:
 		break;
 	}
+#endif
 	return (0);		/* NOT REACHED */
 }
 
@@ -66,6 +67,7 @@ int
 _dwarf_get_reloc_size(Dwarf_Debug dbg, Dwarf_Unsigned rel_type)
 {
 
+#ifdef BUILTIN_ELF_HEADERS
 	switch (dbg->dbg_machine) {
 	case EM_NONE:
 		break;
@@ -127,6 +129,7 @@ _dwarf_get_reloc_size(Dwarf_Debug dbg, D
 	default:
 		break;
 	}
+#endif
 
 	/* unknown relocation. */
 	return (0);



CVS commit: src/external/bsd/elftoolchain/dist/libdwarf

2024-03-27 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Mar 27 21:53:06 UTC 2024

Modified Files:
src/external/bsd/elftoolchain/dist/libdwarf: libdwarf_reloc.c

Log Message:
Don't try to compile the arch-specific relocation code if we don't have the
built-in headers (for tools)


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/bsd/elftoolchain/dist/libdwarf/libdwarf_reloc.c

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



CVS commit: src/external/bsd/openldap/dist/libraries/liblutil

2024-03-04 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Mon Mar  4 17:10:33 UTC 2024

Modified Files:
src/external/bsd/openldap/dist/libraries/liblutil: getpass.c

Log Message:
Fix DEBUG build.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 \
src/external/bsd/openldap/dist/libraries/liblutil/getpass.c

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



CVS commit: src/external/bsd/openldap/dist/libraries/liblutil

2024-03-04 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Mon Mar  4 17:10:33 UTC 2024

Modified Files:
src/external/bsd/openldap/dist/libraries/liblutil: getpass.c

Log Message:
Fix DEBUG build.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 \
src/external/bsd/openldap/dist/libraries/liblutil/getpass.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/openldap/dist/libraries/liblutil/getpass.c
diff -u src/external/bsd/openldap/dist/libraries/liblutil/getpass.c:1.3 src/external/bsd/openldap/dist/libraries/liblutil/getpass.c:1.4
--- src/external/bsd/openldap/dist/libraries/liblutil/getpass.c:1.3	Sat Aug 14 12:14:58 2021
+++ src/external/bsd/openldap/dist/libraries/liblutil/getpass.c	Mon Mar  4 12:10:33 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: getpass.c,v 1.3 2021/08/14 16:14:58 christos Exp $	*/
+/*	$NetBSD: getpass.c,v 1.4 2024/03/04 17:10:33 christos Exp $	*/
 
 /* getpass.c -- get password from user */
 /* $OpenLDAP$ */
@@ -33,7 +33,7 @@
  */
 
 #include 
-__RCSID("$NetBSD: getpass.c,v 1.3 2021/08/14 16:14:58 christos Exp $");
+__RCSID("$NetBSD: getpass.c,v 1.4 2024/03/04 17:10:33 christos Exp $");
 
 #include "portable.h"
 
@@ -86,11 +86,6 @@ lutil_getpass( const char *prompt )
 
 	if( prompt == NULL ) prompt = _("Password: ");
 
-#ifdef DEBUG
-	if (debug & D_TRACE)
-		printf("->getpass(%s)\n", prompt);
-#endif
-
 #if defined(HAVE_TERMIOS_H) || defined(HAVE_SGTTY_H)
 	if ((fi = fopen(TTY, "r")) == NULL)
 		fi = stdin;



CVS commit: src/external/bsd/elftoolchain/lib/libelf

2024-03-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Mar  3 19:13:59 UTC 2024

Modified Files:
src/external/bsd/elftoolchain/lib/libelf: Makefile

Log Message:
add one more source file


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/elftoolchain/lib/libelf/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/bsd/elftoolchain/lib/libelf/Makefile
diff -u src/external/bsd/elftoolchain/lib/libelf/Makefile:1.3 src/external/bsd/elftoolchain/lib/libelf/Makefile:1.4
--- src/external/bsd/elftoolchain/lib/libelf/Makefile:1.3	Fri Feb 19 21:44:02 2016
+++ src/external/bsd/elftoolchain/lib/libelf/Makefile	Sun Mar  3 14:13:59 2024
@@ -55,6 +55,7 @@ SRCS=	elf.c			\
 	libelf_checksum.c	\
 	libelf_data.c		\
 	libelf_ehdr.c		\
+	libelf_elfmachine.c	\
 	libelf_extended.c	\
 	libelf_memory.c		\
 	libelf_open.c		\



CVS commit: src/external/bsd/elftoolchain/lib/libelf

2024-03-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Mar  3 19:13:59 UTC 2024

Modified Files:
src/external/bsd/elftoolchain/lib/libelf: Makefile

Log Message:
add one more source file


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/elftoolchain/lib/libelf/Makefile

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



CVS commit: src/external/bsd/elftoolchain

2024-03-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Mar  3 17:41:49 UTC 2024

Added Files:
src/external/bsd/elftoolchain: README
Removed Files:
src/external/bsd/elftoolchain: addrcsid prepare-import.sh

Log Message:
Use README to import


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/external/bsd/elftoolchain/README
cvs rdiff -u -r1.1 -r0 src/external/bsd/elftoolchain/addrcsid \
src/external/bsd/elftoolchain/prepare-import.sh

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

Added files:

Index: src/external/bsd/elftoolchain/README
diff -u /dev/null src/external/bsd/elftoolchain/README:1.1
--- /dev/null	Sun Mar  3 12:41:49 2024
+++ src/external/bsd/elftoolchain/README	Sun Mar  3 12:41:48 2024
@@ -0,0 +1,6 @@
+#!/bin/sh
+$ svn checkout https://svn.code.sf.net/p/elftoolchain/code/trunk elftoolchain-code
+$ mkdir dist.new
+$ dist/tools/netbsd-base-system-import.sh -m common -m libdwarf -m libelf -s elftoolchain-code -d dist.new
+$ cd dist.new
+cvs -d cvs.netbsd.org import src/external/bsd/elftoolchain FreeBSD r



CVS commit: src/external/bsd/elftoolchain

2024-03-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Mar  3 17:41:49 UTC 2024

Added Files:
src/external/bsd/elftoolchain: README
Removed Files:
src/external/bsd/elftoolchain: addrcsid prepare-import.sh

Log Message:
Use README to import


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/external/bsd/elftoolchain/README
cvs rdiff -u -r1.1 -r0 src/external/bsd/elftoolchain/addrcsid \
src/external/bsd/elftoolchain/prepare-import.sh

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



CVS commit: src/external/bsd/elftoolchain

2024-03-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Mar  3 17:37:35 UTC 2024

Modified Files:
src/external/bsd/elftoolchain/dist/common: _elftc.h elfdefinitions.h
utarray.h uthash.h
src/external/bsd/elftoolchain/dist/common/sys: elfconstants.m4
elfdefinitions.m4
src/external/bsd/elftoolchain/dist/libdwarf: _libdwarf.h dwarf.3
dwarf.h dwarf_abbrev.c dwarf_add_AT_comp_dir.3
dwarf_add_AT_const_value_string.3 dwarf_add_AT_dataref.3
dwarf_add_AT_flag.3 dwarf_add_AT_location_expr.3
dwarf_add_AT_name.3 dwarf_add_AT_producer.3
dwarf_add_AT_ref_address.3 dwarf_add_AT_reference.3
dwarf_add_AT_signed_const.3 dwarf_add_AT_string.3
dwarf_add_AT_targ_address.3 dwarf_add_arange.3
dwarf_add_die_to_debug.3 dwarf_add_directory_decl.3
dwarf_add_expr_addr.3 dwarf_add_expr_gen.3 dwarf_add_fde_inst.3
dwarf_add_file_decl.3 dwarf_add_frame_cie.3 dwarf_add_frame_fde.3
dwarf_add_funcname.3 dwarf_add_line_entry.3 dwarf_add_pubname.3
dwarf_add_typename.3 dwarf_add_varname.3 dwarf_add_weakname.3
dwarf_arange.c dwarf_attr.3 dwarf_attr.c dwarf_attrlist.3
dwarf_attroffset.3 dwarf_attrval.c dwarf_attrval_signed.3
dwarf_child.3 dwarf_cu.c dwarf_dealloc.3 dwarf_dealloc.c
dwarf_def_macro.3 dwarf_die.c dwarf_die_abbrev_code.3
dwarf_die_link.3 dwarf_diename.3 dwarf_dieoffset.3 dwarf_dump.c
dwarf_end_macro_file.3 dwarf_errmsg.3 dwarf_errmsg.c dwarf_errno.3
dwarf_expand_frame_instructions.3 dwarf_expr_current_offset.3
dwarf_expr_into_block.3 dwarf_fde_cfa_offset.3
dwarf_find_macro_value_start.3 dwarf_finish.3 dwarf_finish.c
dwarf_form.c dwarf_formaddr.3 dwarf_formblock.3 dwarf_formexprloc.3
dwarf_formflag.3 dwarf_formref.3 dwarf_formsig8.3
dwarf_formstring.3 dwarf_formudata.3 dwarf_frame.c dwarf_funcs.m4
dwarf_get_AT_name.3 dwarf_get_abbrev.3
dwarf_get_abbrev_children_flag.3 dwarf_get_abbrev_code.3
dwarf_get_abbrev_entry.3 dwarf_get_abbrev_tag.3
dwarf_get_address_size.3 dwarf_get_arange.3 dwarf_get_arange_info.3
dwarf_get_aranges.3 dwarf_get_cie_index.3 dwarf_get_cie_info.3
dwarf_get_cie_of_fde.3 dwarf_get_cu_die_offset.3
dwarf_get_die_infotypes_flag.3 dwarf_get_elf.3
dwarf_get_fde_at_pc.3 dwarf_get_fde_info_for_all_regs.3
dwarf_get_fde_info_for_all_regs3.3
dwarf_get_fde_info_for_cfa_reg3.3 dwarf_get_fde_info_for_reg.3
dwarf_get_fde_info_for_reg3.3 dwarf_get_fde_instr_bytes.3
dwarf_get_fde_list.3 dwarf_get_fde_n.3 dwarf_get_fde_range.3
dwarf_get_form_class.3 dwarf_get_funcs.3 dwarf_get_globals.3
dwarf_get_loclist_entry.3 dwarf_get_macro_details.3
dwarf_get_pubtypes.3 dwarf_get_ranges.3 dwarf_get_relocation_info.3
dwarf_get_relocation_info_count.3 dwarf_get_section_bytes.3
dwarf_get_section_max_offsets.3 dwarf_get_str.3 dwarf_get_types.3
dwarf_get_vars.3 dwarf_get_weaks.3 dwarf_hasattr.3 dwarf_hasform.3
dwarf_highpc.3 dwarf_init.3 dwarf_init.c dwarf_lineno.3
dwarf_lineno.c dwarf_lne_end_sequence.3 dwarf_lne_set_address.3
dwarf_loclist.3 dwarf_loclist.c dwarf_loclist_from_expr.3
dwarf_macinfo.c dwarf_nametbl.m4 dwarf_new_die.3 dwarf_new_expr.3
dwarf_new_fde.3 dwarf_next_cu_header.3 dwarf_next_types_section.3
dwarf_object_init.3 dwarf_pro_arange.c dwarf_pro_attr.c
dwarf_pro_die.c dwarf_pro_expr.c dwarf_pro_finish.c
dwarf_pro_frame.c dwarf_pro_funcs.m4 dwarf_pro_init.c
dwarf_pro_lineno.c dwarf_pro_macinfo.c dwarf_pro_nametbl.m4
dwarf_pro_pubnames.m4 dwarf_pro_reloc.c dwarf_pro_sections.c
dwarf_pro_types.m4 dwarf_pro_vars.m4 dwarf_pro_weaks.m4
dwarf_producer_init.3 dwarf_producer_set_isa.3 dwarf_pubnames.m4
dwarf_pubtypes.m4 dwarf_ranges.c dwarf_reloc.c
dwarf_reset_section_bytes.3 dwarf_sections.c
dwarf_set_frame_cfa_value.3 dwarf_set_reloc_application.3
dwarf_seterrarg.3 dwarf_seterror.c dwarf_srcfiles.3
dwarf_srclines.3 dwarf_start_macro_file.3 dwarf_str.c dwarf_tag.3
dwarf_transform_to_disk_form.3 dwarf_types.m4 dwarf_undef_macro.3
dwarf_vars.m4 dwarf_vendor_ext.3 dwarf_weaks.m4 dwarf_whatattr.3
libdwarf.c libdwarf.h libdwarf_abbrev.c libdwarf_arange.c
libdwarf_attr.c libdwarf_die.c libdwarf_elf_access.c
libdwarf_elf_init.c libdwarf_error.c libdwarf_frame.c
libdwarf_info.c libdwarf_init.c libdwarf_lineno.c libdwarf_loc.c
libdwarf_loclist.c libdwarf_macinfo.c libdwarf_nametbl.c
libdwarf_ranges.c 

CVS commit: src/external/bsd/unbound

2024-02-17 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Feb 17 18:31:19 UTC 2024

Modified Files:
src/external/bsd/unbound/dist: config.guess config.sub
src/external/bsd/unbound/dist/libunbound: unbound.h
src/external/bsd/unbound/dist/services: authzone.c
src/external/bsd/unbound/dist/util: netevent.c
src/external/bsd/unbound/include: config.h
src/external/bsd/unbound/lib/libunbound: Makefile shlib_version
Removed Files:
src/external/bsd/unbound/dist/testcode: mini_tpkg.sh
src/external/bsd/unbound/dist/testdata: ede_cache_snoop_noth_auth.rpl
serve_expired_servfail.rpl subnet_prefetch_with_client_ecs.crpl
src/external/bsd/unbound/dist/testdata/dnscrypt_cert.tdir: precheck.sh
src/external/bsd/unbound/dist/testdata/dnscrypt_cert_chacha.tdir:
precheck.sh
src/external/bsd/unbound/dist/testdata/ede.tdir/bogus: clean.sh

Log Message:
merge differences between 1.16.3 and 1.19.1


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/unbound/dist/config.guess
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/unbound/dist/config.sub
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/unbound/dist/libunbound/unbound.h
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/unbound/dist/services/authzone.c
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testcode/mini_tpkg.sh
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/ede_cache_snoop_noth_auth.rpl \
src/external/bsd/unbound/dist/testdata/subnet_prefetch_with_client_ecs.crpl
cvs rdiff -u -r1.1.1.2 -r0 \
src/external/bsd/unbound/dist/testdata/serve_expired_servfail.rpl
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/dnscrypt_cert.tdir/precheck.sh
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/dnscrypt_cert_chacha.tdir/precheck.sh
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/ede.tdir/bogus/clean.sh
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/unbound/dist/util/netevent.c
cvs rdiff -u -r1.11 -r1.12 src/external/bsd/unbound/include/config.h
cvs rdiff -u -r1.8 -r1.9 src/external/bsd/unbound/lib/libunbound/Makefile
cvs rdiff -u -r1.5 -r1.6 \
src/external/bsd/unbound/lib/libunbound/shlib_version

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/unbound/dist/config.guess
diff -u src/external/bsd/unbound/dist/config.guess:1.7 src/external/bsd/unbound/dist/config.guess:1.8
--- src/external/bsd/unbound/dist/config.guess:1.7	Sat Sep 24 14:11:42 2022
+++ src/external/bsd/unbound/dist/config.guess	Sat Feb 17 13:31:17 2024
@@ -1,10 +1,10 @@
 #! /bin/sh
 # Attempt to guess a canonical system name.
-#   Copyright 1992-2022 Free Software Foundation, Inc.
+#   Copyright 1992-2024 Free Software Foundation, Inc.
 
 # shellcheck disable=SC2006,SC2268 # see below for rationale
 
-timestamp='2022-08-01'
+timestamp='2024-01-01'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -47,7 +47,7 @@ me=`echo "$0" | sed -e 's,.*/,,'`
 usage="\
 Usage: $0 [OPTION]
 
-Output the configuration name of the system \`$me' is run on.
+Output the configuration name of the system '$me' is run on.
 
 Options:
   -h, --help print this help, then exit
@@ -60,13 +60,13 @@ version="\
 GNU config.guess ($timestamp)
 
 Originally written by Per Bothner.
-Copyright 1992-2022 Free Software Foundation, Inc.
+Copyright 1992-2024 Free Software Foundation, Inc.
 
 This is free software; see the source for copying conditions.  There is NO
 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
 
 help="
-Try \`$me --help' for more information."
+Try '$me --help' for more information."
 
 # Parse command line
 while test $# -gt 0 ; do
@@ -102,8 +102,8 @@ GUESS=
 # temporary files to be created and, as you can see below, it is a
 # headache to deal with in a portable fashion.
 
-# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
-# use `HOST_CC' if defined, but it is deprecated.
+# Historically, 'CC_FOR_BUILD' used to be named 'HOST_CC'. We still
+# use 'HOST_CC' if defined, but it is deprecated.
 
 # Portable tmp directory creation inspired by the Autoconf team.
 
@@ -155,6 +155,9 @@ Linux|GNU|GNU/*)
 
 	set_cc_for_build
 	cat <<-EOF > "$dummy.c"
+	#if defined(__ANDROID__)
+	LIBC=android
+	#else
 	#include 
 	#if defined(__UCLIBC__)
 	LIBC=uclibc
@@ -162,6 +165,8 @@ Linux|GNU|GNU/*)
 	LIBC=dietlibc
 	#elif defined(__GLIBC__)
 	LIBC=gnu
+	#elif defined(__LLVM_LIBC__)
+	LIBC=llvm
 	#else
 	#include 
 	/* First heuristic to detect musl libc.  */
@@ -169,6 +174,7 @@ Linux|GNU|GNU/*)
 	LIBC=musl
 	#endif
 	#endif
+	#endif
 	EOF
 	cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`
 	eval "$cc_set_libc"
@@ -459,7 +465,7 

CVS commit: src/external/bsd/unbound

2024-02-17 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Feb 17 18:31:19 UTC 2024

Modified Files:
src/external/bsd/unbound/dist: config.guess config.sub
src/external/bsd/unbound/dist/libunbound: unbound.h
src/external/bsd/unbound/dist/services: authzone.c
src/external/bsd/unbound/dist/util: netevent.c
src/external/bsd/unbound/include: config.h
src/external/bsd/unbound/lib/libunbound: Makefile shlib_version
Removed Files:
src/external/bsd/unbound/dist/testcode: mini_tpkg.sh
src/external/bsd/unbound/dist/testdata: ede_cache_snoop_noth_auth.rpl
serve_expired_servfail.rpl subnet_prefetch_with_client_ecs.crpl
src/external/bsd/unbound/dist/testdata/dnscrypt_cert.tdir: precheck.sh
src/external/bsd/unbound/dist/testdata/dnscrypt_cert_chacha.tdir:
precheck.sh
src/external/bsd/unbound/dist/testdata/ede.tdir/bogus: clean.sh

Log Message:
merge differences between 1.16.3 and 1.19.1


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/unbound/dist/config.guess
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/unbound/dist/config.sub
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/unbound/dist/libunbound/unbound.h
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/unbound/dist/services/authzone.c
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testcode/mini_tpkg.sh
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/ede_cache_snoop_noth_auth.rpl \
src/external/bsd/unbound/dist/testdata/subnet_prefetch_with_client_ecs.crpl
cvs rdiff -u -r1.1.1.2 -r0 \
src/external/bsd/unbound/dist/testdata/serve_expired_servfail.rpl
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/dnscrypt_cert.tdir/precheck.sh
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/dnscrypt_cert_chacha.tdir/precheck.sh
cvs rdiff -u -r1.1.1.1 -r0 \
src/external/bsd/unbound/dist/testdata/ede.tdir/bogus/clean.sh
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/unbound/dist/util/netevent.c
cvs rdiff -u -r1.11 -r1.12 src/external/bsd/unbound/include/config.h
cvs rdiff -u -r1.8 -r1.9 src/external/bsd/unbound/lib/libunbound/Makefile
cvs rdiff -u -r1.5 -r1.6 \
src/external/bsd/unbound/lib/libunbound/shlib_version

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



CVS commit: src/external/bsd/nsd

2024-02-17 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Feb 17 17:43:21 UTC 2024

Modified Files:
src/external/bsd/nsd/dist: configlexer.c configparser.c configparser.h
configure configure.ac options.c server.c util.h zlexer.c
src/external/bsd/nsd/dist/doc: README
src/external/bsd/nsd/include: config.h
src/external/bsd/nsd/lib/libnsd: Makefile
Removed Files:
src/external/bsd/nsd/dist: udbradtree.c udbradtree.h udbzone.c
udbzone.h
src/external/bsd/nsd/dist/.github: FUNDING.yml
src/external/bsd/nsd/dist/contrib: nsd.socket

Log Message:
merge differences between nsd-4.6.0 and nsd-4.8.0


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/external/bsd/nsd/dist/configlexer.c \
src/external/bsd/nsd/dist/configparser.c \
src/external/bsd/nsd/dist/configparser.h
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/nsd/dist/configure
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/nsd/dist/configure.ac
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/nsd/dist/options.c
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/nsd/dist/server.c \
src/external/bsd/nsd/dist/util.h src/external/bsd/nsd/dist/zlexer.c
cvs rdiff -u -r1.1.1.3 -r0 src/external/bsd/nsd/dist/udbradtree.c
cvs rdiff -u -r1.1.1.2 -r0 src/external/bsd/nsd/dist/udbradtree.h \
src/external/bsd/nsd/dist/udbzone.h
cvs rdiff -u -r1.1.1.1 -r0 src/external/bsd/nsd/dist/udbzone.c
cvs rdiff -u -r1.1.1.1 -r0 src/external/bsd/nsd/dist/.github/FUNDING.yml
cvs rdiff -u -r1.1.1.1 -r0 src/external/bsd/nsd/dist/contrib/nsd.socket
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/nsd/dist/doc/README
cvs rdiff -u -r1.11 -r1.12 src/external/bsd/nsd/include/config.h
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/nsd/lib/libnsd/Makefile

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



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

2024-02-13 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Feb 13 18:43:45 UTC 2024

Modified Files:
src/external/bsd/wpa/dist/src/eap_peer: eap_config.h eap_peap.c
eap_tls_common.c eap_tls_common.h
src/external/bsd/wpa/dist/wpa_supplicant: wpa_supplicant.conf

Log Message:
https://www.phoronix.com/news/IWD-WPA-WiFi-Auth-Vulns
https://www.top10vpn.com/research/wifi-vulnerabilities/

PEAP client: Update Phase 2 authentication requirements

The previous PEAP client behavior allowed the server to skip Phase 2
authentication with the expectation that the server was authenticated
during Phase 1 through TLS server certificate validation. Various PEAP
specifications are not exactly clear on what the behavior on this front
is supposed to be and as such, this ended up being more flexible than
the TTLS/FAST/TEAP cases. However, this is not really ideal when
unfortunately common misconfiguration of PEAP is used in deployed
devices where the server trust root (ca_cert) is not configured or the
user has an easy option for allowing this validation step to be skipped.

Change the default PEAP client behavior to be to require Phase 2
authentication to be successfully completed for cases where TLS session
resumption is not used and the client certificate has not been
configured. Those two exceptions are the main cases where a deployed
authentication server might skip Phase 2 and as such, where a more
strict default behavior could result in undesired interoperability
issues. Requiring Phase 2 authentication will end up disabling TLS
session resumption automatically to avoid interoperability issues.

Allow Phase 2 authentication behavior to be configured with a new phase1
configuration parameter option:
'phase2_auth' option can be used to control Phase 2 (i.e., within TLS
tunnel) behavior for PEAP:
 * 0 = do not require Phase 2 authentication
 * 1 = require Phase 2 authentication when client certificate
   (private_key/client_cert) is no used and TLS session resumption was
   not used (default)
 * 2 = require Phase 2 authentication in all cases


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.7 -r1.2 \
src/external/bsd/wpa/dist/src/eap_peer/eap_config.h \
src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.h
cvs rdiff -u -r1.1.1.8 -r1.2 \
src/external/bsd/wpa/dist/src/eap_peer/eap_peap.c \
src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.c
cvs rdiff -u -r1.1.1.8 -r1.2 \
src/external/bsd/wpa/dist/wpa_supplicant/wpa_supplicant.conf

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



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

2024-02-13 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Feb 13 18:43:45 UTC 2024

Modified Files:
src/external/bsd/wpa/dist/src/eap_peer: eap_config.h eap_peap.c
eap_tls_common.c eap_tls_common.h
src/external/bsd/wpa/dist/wpa_supplicant: wpa_supplicant.conf

Log Message:
https://www.phoronix.com/news/IWD-WPA-WiFi-Auth-Vulns
https://www.top10vpn.com/research/wifi-vulnerabilities/

PEAP client: Update Phase 2 authentication requirements

The previous PEAP client behavior allowed the server to skip Phase 2
authentication with the expectation that the server was authenticated
during Phase 1 through TLS server certificate validation. Various PEAP
specifications are not exactly clear on what the behavior on this front
is supposed to be and as such, this ended up being more flexible than
the TTLS/FAST/TEAP cases. However, this is not really ideal when
unfortunately common misconfiguration of PEAP is used in deployed
devices where the server trust root (ca_cert) is not configured or the
user has an easy option for allowing this validation step to be skipped.

Change the default PEAP client behavior to be to require Phase 2
authentication to be successfully completed for cases where TLS session
resumption is not used and the client certificate has not been
configured. Those two exceptions are the main cases where a deployed
authentication server might skip Phase 2 and as such, where a more
strict default behavior could result in undesired interoperability
issues. Requiring Phase 2 authentication will end up disabling TLS
session resumption automatically to avoid interoperability issues.

Allow Phase 2 authentication behavior to be configured with a new phase1
configuration parameter option:
'phase2_auth' option can be used to control Phase 2 (i.e., within TLS
tunnel) behavior for PEAP:
 * 0 = do not require Phase 2 authentication
 * 1 = require Phase 2 authentication when client certificate
   (private_key/client_cert) is no used and TLS session resumption was
   not used (default)
 * 2 = require Phase 2 authentication in all cases


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.7 -r1.2 \
src/external/bsd/wpa/dist/src/eap_peer/eap_config.h \
src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.h
cvs rdiff -u -r1.1.1.8 -r1.2 \
src/external/bsd/wpa/dist/src/eap_peer/eap_peap.c \
src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.c
cvs rdiff -u -r1.1.1.8 -r1.2 \
src/external/bsd/wpa/dist/wpa_supplicant/wpa_supplicant.conf

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/wpa/dist/src/eap_peer/eap_config.h
diff -u src/external/bsd/wpa/dist/src/eap_peer/eap_config.h:1.1.1.7 src/external/bsd/wpa/dist/src/eap_peer/eap_config.h:1.2
--- src/external/bsd/wpa/dist/src/eap_peer/eap_config.h:1.1.1.7	Sun Feb 28 20:37:57 2021
+++ src/external/bsd/wpa/dist/src/eap_peer/eap_config.h	Tue Feb 13 13:43:45 2024
@@ -470,6 +470,14 @@ struct eap_peer_config {
 	 * 1 = use cryptobinding if server supports it
 	 * 2 = require cryptobinding
 	 *
+	 * phase2_auth option can be used to control Phase 2 (i.e., within TLS
+	 * tunnel) behavior for PEAP:
+	 * 0 = do not require Phase 2 authentication
+	 * 1 = require Phase 2 authentication when client certificate
+	 *  (private_key/client_cert) is no used and TLS session resumption was
+	 *  not used (default)
+	 * 2 = require Phase 2 authentication in all cases
+	 *
 	 * EAP-WSC (WPS) uses following options: pin=Device_Password and
 	 * uuid=Device_UUID
 	 *
Index: src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.h
diff -u src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.h:1.1.1.7 src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.h:1.2
--- src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.h:1.1.1.7	Sun Feb 28 20:37:57 2021
+++ src/external/bsd/wpa/dist/src/eap_peer/eap_tls_common.h	Tue Feb 13 13:43:45 2024
@@ -79,6 +79,11 @@ struct eap_ssl_data {
 	 * tls_v13 - Whether TLS v1.3 or newer is used
 	 */
 	int tls_v13;
+
+	/**
+	 * client_cert_conf: Whether client certificate has been configured
+	 */
+	bool client_cert_conf;
 };
 
 

Index: src/external/bsd/wpa/dist/src/eap_peer/eap_peap.c
diff -u src/external/bsd/wpa/dist/src/eap_peer/eap_peap.c:1.1.1.8 src/external/bsd/wpa/dist/src/eap_peer/eap_peap.c:1.2
--- src/external/bsd/wpa/dist/src/eap_peer/eap_peap.c:1.1.1.8	Sun Feb 28 20:37:57 2021
+++ src/external/bsd/wpa/dist/src/eap_peer/eap_peap.c	Tue Feb 13 13:43:45 2024
@@ -67,6 +67,7 @@ struct eap_peap_data {
 	u8 cmk[20];
 	int soh; /* Whether IF-TNCCS-SOH (Statement of Health; Microsoft NAP)
 		  * is enabled. */
+	enum { NO_AUTH, FOR_INITIAL, ALWAYS } phase2_auth;
 };
 
 
@@ -114,6 +115,19 @@ static void eap_peap_parse_phase1(struct
 		wpa_printf(MSG_DEBUG, "EAP-PEAP: Require cryptobinding");
 	}
 
+	if (os_strstr(phase1, "phase2_auth=0")) {
+		data->phase2_auth = NO_AUTH;
+		wpa_printf(MSG_DEBUG,
+			   

CVS commit: src/external/bsd/blocklist/bin

2024-02-09 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  9 15:15:32 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: conf.c

Log Message:
PR/57905: Mark Davies: handle empty string.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/blocklist/bin/conf.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/blocklist/bin/conf.c
diff -u src/external/bsd/blocklist/bin/conf.c:1.5 src/external/bsd/blocklist/bin/conf.c:1.6
--- src/external/bsd/blocklist/bin/conf.c:1.5	Thu Feb  8 19:39:16 2024
+++ src/external/bsd/blocklist/bin/conf.c	Fri Feb  9 10:15:32 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: conf.c,v 1.5 2024/02/09 00:39:16 christos Exp $	*/
+/*	$NetBSD: conf.c,v 1.6 2024/02/09 15:15:32 christos Exp $	*/
 
 /*-
  * Copyright (c) 2015 The NetBSD Foundation, Inc.
@@ -33,7 +33,7 @@
 #endif
 
 #include 
-__RCSID("$NetBSD: conf.c,v 1.5 2024/02/09 00:39:16 christos Exp $");
+__RCSID("$NetBSD: conf.c,v 1.6 2024/02/09 15:15:32 christos Exp $");
 
 #include 
 #ifdef HAVE_LIBUTIL_H
@@ -269,6 +269,8 @@ conf_gethostport(const char *f, size_t l
 #endif
 			port = >sin6_port;
 		}
+		if (!*pstr)
+			pstr = "*";
 	} else if (pstr != p || strchr(p, '.') || conf_is_interface(p)) {
 		if (pstr == p)
 			pstr = "*";



CVS commit: src/external/bsd/blocklist/bin

2024-02-09 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  9 15:15:32 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: conf.c

Log Message:
PR/57905: Mark Davies: handle empty string.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/blocklist/bin/conf.c

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



CVS commit: src/external/bsd/blocklist/etc

2024-02-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Feb  9 01:00:12 UTC 2024

Modified Files:
src/external/bsd/blocklist/etc: blocklistd.conf

Log Message:
add an IPv6 example to blocklistd.conf example file


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/blocklist/etc/blocklistd.conf

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/blocklist/etc/blocklistd.conf
diff -u src/external/bsd/blocklist/etc/blocklistd.conf:1.2 src/external/bsd/blocklist/etc/blocklistd.conf:1.3
--- src/external/bsd/blocklist/etc/blocklistd.conf:1.2	Mon Jun 15 21:27:57 2020
+++ src/external/bsd/blocklist/etc/blocklistd.conf	Fri Feb  9 01:00:12 2024
@@ -10,5 +10,6 @@ domain		*	*	named		*	3	12h
 # adr/mask:port	type	proto	owner		name	nfail	disable
 [remote]
 #129.168.0.0/16	*	*	*		=	*	*
+#[2001:db8::]/32:ssh	*	*	*		=	*	*
 #6161		=	=	=		=/24	=	=
 #*		stream	tcp	*		=	=	=



CVS commit: src/external/bsd/blocklist/etc

2024-02-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Feb  9 01:00:12 UTC 2024

Modified Files:
src/external/bsd/blocklist/etc: blocklistd.conf

Log Message:
add an IPv6 example to blocklistd.conf example file


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/blocklist/etc/blocklistd.conf

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



CVS commit: src/external/bsd/blocklist/bin

2024-02-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Feb  9 00:59:08 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: blocklistd.conf.5

Log Message:
add an IPv6 example to blocklistd.conf(5)


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/blocklist/bin/blocklistd.conf.5

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/blocklist/bin/blocklistd.conf.5
diff -u src/external/bsd/blocklist/bin/blocklistd.conf.5:1.2 src/external/bsd/blocklist/bin/blocklistd.conf.5:1.3
--- src/external/bsd/blocklist/bin/blocklistd.conf.5:1.2	Mon Jun 15 02:29:44 2020
+++ src/external/bsd/blocklist/bin/blocklistd.conf.5	Fri Feb  9 00:59:08 2024
@@ -1,4 +1,4 @@
-.\" $NetBSD: blocklistd.conf.5,v 1.2 2020/06/15 02:29:44 christos Exp $
+.\" $NetBSD: blocklistd.conf.5,v 1.3 2024/02/09 00:59:08 wiz Exp $
 .\"
 .\" Copyright (c) 2015 The NetBSD Foundation, Inc.
 .\" All rights reserved.
@@ -27,7 +27,7 @@
 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\" POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd May 18, 2020
+.Dd February 9, 2024
 .Dt BLOCKLISTD.CONF 5
 .Os
 .Sh NAME
@@ -209,6 +209,8 @@ bnx0:ssh	*	*	*	*	3	6h
 [remote]
 # Never block 1.2.3.4
 1.2.3.4:ssh	*	*	*	*	*	*
+# Never block the example IPv6 subnet either
+[2001:db8::]/32:ssh	*	*	*	*	*	*
 # For addresses coming from 8.8.0.0/16 block class C networks instead
 # individual hosts, but keep the rest of the blocking parameters the same.
 8.8.0.0/16:ssh	*	*	*	/24	=	=



CVS commit: src/external/bsd/blocklist/bin

2024-02-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Feb  9 00:59:08 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: blocklistd.conf.5

Log Message:
add an IPv6 example to blocklistd.conf(5)


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/blocklist/bin/blocklistd.conf.5

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



CVS commit: src/external/bsd/blocklist

2024-02-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Feb  9 00:53:30 UTC 2024

Modified Files:
src/external/bsd/blocklist: README

Log Message:
Spelling fixes


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/blocklist/README

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/blocklist/README
diff -u src/external/bsd/blocklist/README:1.2 src/external/bsd/blocklist/README:1.3
--- src/external/bsd/blocklist/README:1.2	Mon Jun 15 21:27:57 2020
+++ src/external/bsd/blocklist/README	Fri Feb  9 00:53:30 2024
@@ -1,4 +1,4 @@
-# $NetBSD: README,v 1.2 2020/06/15 21:27:57 christos Exp $
+# $NetBSD: README,v 1.3 2024/02/09 00:53:30 wiz Exp $
 
 This package contains library that can be used by network daemons to
 communicate with a packet filter via a daemon to enforce opening and
@@ -15,7 +15,7 @@ blocklistd=YES in /etc/rc.conf, start it
 
 There is also a startup file in etc/rc.d/blocklistd
 
-Patches to various daemons to add blocklisting capabilitiers are in the
+Patches to various daemons to add blocklisting capabilities are in the
 "diff" directory:
 - OpenSSH: diff/ssh.diff [tcp socket example]
 - Bind: diff/named.diff [both tcp and udp]
@@ -24,7 +24,7 @@ Patches to various daemons to add blockl
 These patches have been applied to NetBSD-current.
 
 The network daemon (for example sshd) communicates to blocklistd, via
-a unix socket like syslog. The library calls are simple and everything
+a Unix socket like syslog. The library calls are simple and everything
 is handled by the library. In the simplest form the only thing the
 daemon needs to do is to call:
 
@@ -60,11 +60,11 @@ ssh		stream	tcp6		*	*	6	60m
 http		stream	tcp		*	*	6	60m
 
 Here note that owner is * because the connection is done from the
-child ssh socket which runs with user privs. We treat ipv4 connections
+child ssh socket which runs with user privs. We treat IPv4 connections
 differently by maintaining two different rules one for the external
 interface and one from the internal We also register for both tcp
 and tcp6 since those are different listening sockets and addresses;
-we don't bother with ipv6 and separate rules. We use nfail = 6,
+we don't bother with IPv6 and separate rules. We use nfail = 6,
 because ssh allows 3 password attempts per connection, and this
 will let us have 2 connections before blocking. Finally we block
 for an hour; we could block forever too by specifying * in the
@@ -100,7 +100,7 @@ group "internal" on $int_if {
 
 You can use 'blocklistctl dump -a' to list all the current entries
 in the database; the ones that have nfail / where urrent
->= otal, should have an id assosiated with them; this means that
+>= otal, should have an id associated with them; this means that
 there is a packet filter rule added for that entry. For npf, you
 can examine the packet filter dynamic rule entries using 'npfctl
 rule  list'.  The number of current entries can exceed



CVS commit: src/external/bsd/blocklist

2024-02-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Feb  9 00:53:30 UTC 2024

Modified Files:
src/external/bsd/blocklist: README

Log Message:
Spelling fixes


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/blocklist/README

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



CVS commit: src/external/bsd/blocklist/bin

2024-02-08 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  9 00:39:16 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: conf.c

Log Message:
fix typo


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/blocklist/bin/conf.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/blocklist/bin/conf.c
diff -u src/external/bsd/blocklist/bin/conf.c:1.4 src/external/bsd/blocklist/bin/conf.c:1.5
--- src/external/bsd/blocklist/bin/conf.c:1.4	Thu Feb  8 19:37:06 2024
+++ src/external/bsd/blocklist/bin/conf.c	Thu Feb  8 19:39:16 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: conf.c,v 1.4 2024/02/09 00:37:06 christos Exp $	*/
+/*	$NetBSD: conf.c,v 1.5 2024/02/09 00:39:16 christos Exp $	*/
 
 /*-
  * Copyright (c) 2015 The NetBSD Foundation, Inc.
@@ -33,7 +33,7 @@
 #endif
 
 #include 
-__RCSID("$NetBSD: conf.c,v 1.4 2024/02/09 00:37:06 christos Exp $");
+__RCSID("$NetBSD: conf.c,v 1.5 2024/02/09 00:39:16 christos Exp $");
 
 #include 
 #ifdef HAVE_LIBUTIL_H
@@ -308,7 +308,7 @@ conf_gethostport(const char *f, size_t l
 		return -1;
 
 	if (port && c->c_port != FSTAR && c->c_port != FEQUAL)
-		*port = htons((in_port_t)c->c_port)
+		*port = htons((in_port_t)c->c_port);
 	return 0;
 out:
 	(*lfun)(LOG_ERR, "%s: %s, %zu: Bad address [%s]", __func__, f, l, p);



CVS commit: src/external/bsd/blocklist/bin

2024-02-08 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  9 00:39:16 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: conf.c

Log Message:
fix typo


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/blocklist/bin/conf.c

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



CVS commit: src/external/bsd/blocklist/bin

2024-02-08 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  9 00:37:06 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: conf.c

Log Message:
PR/57905: Mark Davies: blocklistd fails to parse ipv6 addresses.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/blocklist/bin/conf.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/blocklist/bin/conf.c
diff -u src/external/bsd/blocklist/bin/conf.c:1.3 src/external/bsd/blocklist/bin/conf.c:1.4
--- src/external/bsd/blocklist/bin/conf.c:1.3	Fri Nov 18 11:01:00 2022
+++ src/external/bsd/blocklist/bin/conf.c	Thu Feb  8 19:37:06 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: conf.c,v 1.3 2022/11/18 16:01:00 christos Exp $	*/
+/*	$NetBSD: conf.c,v 1.4 2024/02/09 00:37:06 christos Exp $	*/
 
 /*-
  * Copyright (c) 2015 The NetBSD Foundation, Inc.
@@ -33,7 +33,7 @@
 #endif
 
 #include 
-__RCSID("$NetBSD: conf.c,v 1.3 2022/11/18 16:01:00 christos Exp $");
+__RCSID("$NetBSD: conf.c,v 1.4 2024/02/09 00:37:06 christos Exp $");
 
 #include 
 #ifdef HAVE_LIBUTIL_H
@@ -261,7 +261,7 @@ conf_gethostport(const char *f, size_t l
 		if (debug)
 			(*lfun)(LOG_DEBUG, "%s: host6 %s", __func__, p);
 		if (strcmp(p, "*") != 0) {
-			if (inet_pton(AF_INET6, p, >sin6_addr) == -1)
+			if (inet_pton(AF_INET6, p, >sin6_addr) != 1)
 goto out;
 			sin6->sin6_family = AF_INET6;
 #ifdef HAVE_STRUCT_SOCKADDR_SA_LEN
@@ -308,10 +308,10 @@ conf_gethostport(const char *f, size_t l
 		return -1;
 
 	if (port && c->c_port != FSTAR && c->c_port != FEQUAL)
-		*port = htons((in_port_t)c->c_port);
+		*port = htons((in_port_t)c->c_port)
 	return 0;
 out:
-	(*lfun)(LOG_ERR, "%s: %s, %zu: Bad address [%s]", __func__, f, l, pstr);
+	(*lfun)(LOG_ERR, "%s: %s, %zu: Bad address [%s]", __func__, f, l, p);
 	return -1;
 out1:
 	(*lfun)(LOG_ERR, "%s: %s, %zu: Can't specify mask %d with "
@@ -1172,7 +1172,7 @@ conf_parse(const char *f)
 		return;
 	}
 
-	lineno = 1;
+	lineno = 0;
 
 	confset_init();
 	confset_init();



CVS commit: src/external/bsd/blocklist/bin

2024-02-08 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  9 00:37:06 UTC 2024

Modified Files:
src/external/bsd/blocklist/bin: conf.c

Log Message:
PR/57905: Mark Davies: blocklistd fails to parse ipv6 addresses.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/blocklist/bin/conf.c

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



CVS commit: src/external/bsd/fetch/dist/libfetch

2024-02-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  2 22:19:05 UTC 2024

Modified Files:
src/external/bsd/fetch/dist/libfetch: common.c common.h fetch.3 ftp.c
http.c

Log Message:
Sync with pkgsrc and try to fix more memory corruption from PR/57179.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/fetch/dist/libfetch/common.c
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/fetch/dist/libfetch/common.h
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/fetch/dist/libfetch/fetch.3 \
src/external/bsd/fetch/dist/libfetch/http.c
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/fetch/dist/libfetch/ftp.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/fetch/dist/libfetch/common.c
diff -u src/external/bsd/fetch/dist/libfetch/common.c:1.6 src/external/bsd/fetch/dist/libfetch/common.c:1.7
--- src/external/bsd/fetch/dist/libfetch/common.c:1.6	Wed Jan  3 06:40:38 2024
+++ src/external/bsd/fetch/dist/libfetch/common.c	Fri Feb  2 17:19:05 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: common.c,v 1.6 2024/01/03 11:40:38 riastradh Exp $	*/
+/*	$NetBSD: common.c,v 1.7 2024/02/02 22:19:05 christos Exp $	*/
 /*-
  * Copyright (c) 1998-2004 Dag-Erling Coïdan Smørgrav
  * Copyright (c) 2008, 2010 Joerg Sonnenberger 
@@ -41,6 +41,13 @@
 #include 
 #include 
 #include 
+#if defined(HAVE_POLL_H) || defined(NETBSD)
+#include 
+#define HAVE_POLL
+#elif HAVE_SYS_POLL_H
+#define HAVE_POLL
+#include 
+#endif
 
 #include 
 #include 
@@ -236,6 +243,9 @@ fetch_reopen(int sd)
 	conn->next_buf = NULL;
 	conn->next_len = 0;
 	conn->sd = sd;
+#ifdef HAVE_POLL
+	conn->buf_events = POLLIN;
+#endif
 	return (conn);
 }
 
@@ -316,6 +326,7 @@ fetch_connect(struct url *url, int af, i
 	if ((conn = fetch_reopen(sd)) == NULL) {
 		fetch_syserr();
 		close(sd);
+		return (NULL);
 	}
 	conn->cache_url = fetchCopyURL(url);
 	conn->cache_af = af;
@@ -398,7 +409,7 @@ void
 fetch_cache_put(conn_t *conn, int (*closecb)(conn_t *))
 {
 	conn_t *iter, *last, *oiter;
-	int global_count, host_count;
+	int global_count, host_count, added;
 
 	if (conn->cache_url == NULL || cache_global_limit == 0) {
 		(*closecb)(conn);
@@ -409,20 +420,23 @@ fetch_cache_put(conn_t *conn, int (*clos
 	last = NULL;
 	for (iter = connection_cache; iter; ) {
 		++global_count;
-		if (strcmp(conn->cache_url->host, iter->cache_url->host) == 0)
+		added = !strcmp(conn->cache_url->host, iter->cache_url->host);
+		if (added)
 			++host_count;
 		if (global_count < cache_global_limit &&
-		host_count < cache_per_host_limit)
+		host_count < cache_per_host_limit) {
 			oiter = NULL;
-		else {
+			last = iter;
+		} else {
 			--global_count;
+			if (added)
+--host_count;
 			if (last != NULL)
 last->next_cached = iter->next_cached;
 			else
 connection_cache = iter->next_cached;
 			oiter = iter;
 		}
-		last = iter;
 		iter = iter->next_cached;
 		if (oiter)
 			(*oiter->cache_close)(oiter);
@@ -437,7 +451,7 @@ fetch_cache_put(conn_t *conn, int (*clos
  * Enable SSL on a connection.
  */
 int
-fetch_ssl(conn_t *conn, int verbose)
+fetch_ssl(conn_t *conn, const struct url *URL, int verbose)
 {
 
 #ifdef WITH_SSL
@@ -462,11 +476,17 @@ fetch_ssl(conn_t *conn, int verbose)
 		fprintf(stderr, "SSL context creation failed\n");
 		return (-1);
 	}
+	conn->buf_events = 0;
 	SSL_set_fd(conn->ssl, conn->sd);
-	if (!SSL_set_tlsext_host_name(conn->ssl, conn->cache_url->host)) {
-		fprintf(stderr, "SSL hostname setting failed\n"); 
+#if OPENSSL_VERSION_NUMBER >= 0x0090806fL && !defined(OPENSSL_NO_TLSEXT)
+	if (!SSL_set_tlsext_host_name(conn->ssl, (char *)(uintptr_t)URL->host))
+	{
+		fprintf(stderr,
+		"TLS server name indication extension failed for host %s\n",
+		URL->host);
 		return (-1);
 	}
+#endif
 	if (SSL_connect(conn->ssl) == -1){
 		ERR_print_errors_fp(stderr);
 		return (-1);
@@ -498,6 +518,17 @@ fetch_ssl(conn_t *conn, int verbose)
 #endif
 }
 
+#ifdef HAVE_POLL
+static int
+compute_timeout(const struct timeval *tv)
+{
+	struct timeval cur;
+
+	gettimeofday(, NULL);
+	return (tv->tv_sec - cur.tv_sec) * 1000
+	+ (tv->tv_usec - cur.tv_usec) / 1000;
+}
+#endif
 
 /*
  * Read a character from a connection w/ timeout
@@ -505,8 +536,13 @@ fetch_ssl(conn_t *conn, int verbose)
 ssize_t
 fetch_read(conn_t *conn, char *buf, size_t len)
 {
-	struct timeval now, timeout, waittv;
+	struct timeval timeout_end;
+#ifdef HAVE_POLL
+	struct pollfd pfd;
+#else
 	fd_set readfds;
+#endif
+	int timeout_cur;
 	ssize_t rlen;
 	int r;
 
@@ -523,17 +559,41 @@ fetch_read(conn_t *conn, char *buf, size
 	}
 
 	if (fetchTimeout) {
+#ifndef HAVE_POLL
 		FD_ZERO();
-		gettimeofday(, NULL);
-		timeout.tv_sec += fetchTimeout;
+#endif
+		gettimeofday(_end, NULL);
+		timeout_end.tv_sec += fetchTimeout;
 	}
 
 	for (;;) {
+#ifdef HAVE_POLL
+		pfd.fd = conn->sd;
+		pfd.events = conn->buf_events;
+		if (fetchTimeout && pfd.events) {
+			do {
+

CVS commit: src/external/bsd/fetch/dist/libfetch

2024-02-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Feb  2 22:19:05 UTC 2024

Modified Files:
src/external/bsd/fetch/dist/libfetch: common.c common.h fetch.3 ftp.c
http.c

Log Message:
Sync with pkgsrc and try to fix more memory corruption from PR/57179.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/external/bsd/fetch/dist/libfetch/common.c
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/fetch/dist/libfetch/common.h
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/fetch/dist/libfetch/fetch.3 \
src/external/bsd/fetch/dist/libfetch/http.c
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/fetch/dist/libfetch/ftp.c

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



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

2024-01-15 Thread Patrick Welche
Module Name:src
Committed By:   prlw1
Date:   Mon Jan 15 12:38:56 UTC 2024

Modified Files:
src/external/bsd/libproc/dist: proc_sym.c

Log Message:
libproc: sanitize process symbols so binary doesn't end up in dtrace profiling
>From RVP on current-users
https://mail-index.netbsd.org/current-users/2023/12/27/msg044840.html


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/libproc/dist/proc_sym.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/libproc/dist/proc_sym.c
diff -u src/external/bsd/libproc/dist/proc_sym.c:1.4 src/external/bsd/libproc/dist/proc_sym.c:1.5
--- src/external/bsd/libproc/dist/proc_sym.c:1.4	Thu Jun 15 23:44:58 2017
+++ src/external/bsd/libproc/dist/proc_sym.c	Mon Jan 15 12:38:56 2024
@@ -32,7 +32,7 @@
 #ifdef __FBSDID
 __FBSDID("$FreeBSD: head/lib/libproc/proc_sym.c 279946 2015-03-13 04:26:48Z stas $");
 #else
-__RCSID("$NetBSD: proc_sym.c,v 1.4 2017/06/15 23:44:58 kamil Exp $");
+__RCSID("$NetBSD: proc_sym.c,v 1.5 2024/01/15 12:38:56 prlw1 Exp $");
 #endif
 
 #include 
@@ -141,6 +141,10 @@ proc_objname(struct proc_handle *p, uint
 	size_t i;
 	rd_loadobj_t *rdl;
 
+	if (p->nobjs == 0)  
+		if (proc_rdagent(p) == NULL)	
+			return (NULL);  
+
 	for (i = 0; i < p->nobjs; i++) {
 		rdl = >rdobjs[i];
 		if (addr >= rdl->rdl_saddr && addr < rdl->rdl_eaddr) {



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

2024-01-15 Thread Patrick Welche
Module Name:src
Committed By:   prlw1
Date:   Mon Jan 15 12:38:56 UTC 2024

Modified Files:
src/external/bsd/libproc/dist: proc_sym.c

Log Message:
libproc: sanitize process symbols so binary doesn't end up in dtrace profiling
>From RVP on current-users
https://mail-index.netbsd.org/current-users/2023/12/27/msg044840.html


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

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



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-01-04 Thread Valery Ushakov
Module Name:src
Committed By:   uwe
Date:   Thu Jan  4 13:20:22 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
tmux: perform substitution(s) in the man page


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/external/bsd/tmux/usr.bin/tmux/Makefile

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



CVS commit: src/external/bsd/tmux/usr.bin/tmux

2024-01-04 Thread Valery Ushakov
Module Name:src
Committed By:   uwe
Date:   Thu Jan  4 13:20:22 UTC 2024

Modified Files:
src/external/bsd/tmux/usr.bin/tmux: Makefile

Log Message:
tmux: perform substitution(s) in the man page


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/external/bsd/tmux/usr.bin/tmux/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/bsd/tmux/usr.bin/tmux/Makefile
diff -u src/external/bsd/tmux/usr.bin/tmux/Makefile:1.31 src/external/bsd/tmux/usr.bin/tmux/Makefile:1.32
--- src/external/bsd/tmux/usr.bin/tmux/Makefile:1.31	Wed Jun 28 22:47:39 2023
+++ src/external/bsd/tmux/usr.bin/tmux/Makefile	Thu Jan  4 13:20:22 2024
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.31 2023/06/28 22:47:39 wiz Exp $
+# $NetBSD: Makefile,v 1.32 2024/01/04 13:20:22 uwe Exp $
 
 .include 
 
@@ -247,4 +247,10 @@ COPTS.tty.c += -Wno-pointer-sign
 COPTS.utempter.c+=	${CC_WNO_STRINGOP_TRUNCATION}
 COPTS.window-copy.c+=	${CC_WNO_MAYBE_UNINITIALIZED} -Wno-pointer-sign
 
+# The man page needs substitutions, but the dist file usurps the
+# output file suffix.
+.NOPATH: tmux.1
+tmux.1: $(SRCDIR)/tmux.1
+	sed -e 's|@SYSCONFDIR@|/etc|g' $> > $@
+
 .include 



CVS commit: src/external/bsd/fetch/dist/libfetch

2024-01-03 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Wed Jan  3 11:40:38 UTC 2024

Modified Files:
src/external/bsd/fetch/dist/libfetch: common.c

Log Message:
fetch(3): Backport SSL validation from pkgsrc libfetch 2.40.

We should really sync with pkgsrc libfetch to avoid divergence, but
this is a low-risk, high-priority change for NetBSD 10:

https://mail-index.netbsd.org/pkgsrc-changes/2024/01/03/msg290052.html


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/bsd/fetch/dist/libfetch/common.c

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



  1   2   3   4   5   6   7   8   9   10   >