From: mpi Date: Fri, 6 Sep 2024 08:00:36 +0000 (+0000) Subject: Regression for '%c'. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=d0375a9d7948c2090826e3c9b4d2318f83629030;p=openbsd Regression for '%c'. From Christian Ludwig. --- diff --git a/regress/usr.sbin/btrace/Makefile b/regress/usr.sbin/btrace/Makefile index fb0a37bfc4e..10fc07fd091 100644 --- a/regress/usr.sbin/btrace/Makefile +++ b/regress/usr.sbin/btrace/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.31 2024/02/05 15:30:04 mpi Exp $ +# $OpenBSD: Makefile,v 1.32 2024/09/06 08:00:36 mpi Exp $ BTRACE?= /usr/sbin/btrace ALLOWDT!= sysctl -n kern.allowdt 2>/dev/null @@ -8,8 +8,8 @@ BT_LANG_SCRIPTS= arithm beginend beginend-argn boolean comments \ delete exit histempty if \ map mapclear mapempty mapsyntax mapzero map-unnamed \ maxoperand min+max+sum multismts nsecs+var \ - precedence print read-map-after-clear staticv-empty \ - syntaxerror tuple tupleeval vareval + precedence print printf read-map-after-clear \ + staticv-empty syntaxerror tuple tupleeval vareval BT_ARG_LANG_SCRIPTS= staticv str diff --git a/regress/usr.sbin/btrace/multismts.bt b/regress/usr.sbin/btrace/multismts.bt index 74eaa498676..67fbf7befa1 100644 --- a/regress/usr.sbin/btrace/multismts.bt +++ b/regress/usr.sbin/btrace/multismts.bt @@ -1,5 +1,5 @@ // Test multiple statements inside a single block; BEGIN { printf("One"); printf(", %d", "2"); - printf(" %s three%c\n", "and", "!"); + printf(" %s three!\n", "and"); } diff --git a/regress/usr.sbin/btrace/printf.bt b/regress/usr.sbin/btrace/printf.bt new file mode 100644 index 00000000000..f025d0bbc27 --- /dev/null +++ b/regress/usr.sbin/btrace/printf.bt @@ -0,0 +1,4 @@ +BEGIN { + $c = 0x41; // 'A' + printf("%c%c%c\n", $c, 0x41, 65); +} diff --git a/regress/usr.sbin/btrace/printf.ok b/regress/usr.sbin/btrace/printf.ok new file mode 100644 index 00000000000..43d5a8ed6ef --- /dev/null +++ b/regress/usr.sbin/btrace/printf.ok @@ -0,0 +1 @@ +AAA