From nobody Fri Oct 02 20:43:14 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4hxLMr493vz6tYJl for ; Fri, 02 Oct 2026 20:43:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "YR2" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hxLMr23JRz4c5y for ; Fri, 02 Oct 2026 20:43:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1790973800; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/kSNxjZwbUgsJOIi5EfVqYxOWlxE2byJTOGZToxdVTQ=; b=ti+vNm5394fnprT8p5kU2wBGuh6fkjb1YpgZVlgeLOcN3E1GPuP6GVXwp82k2LkUljSOkn nkSXipfQlsV0YGwXuD9PpP0BXLgv+CPVmeKPFE/hNRGFsFQC/7zl0rcDoYyjoowa4+CZkQ 3/0+a88ohnHOL1iWWFkKeoAApRKYcY0YvumLHn4goDv76x1zCiJizHYKkBIAeW43NIyMxr qKO1CAr9258VwsDe9xlNuOSQJXgVRO1JSzmRp4hvlyRFQ9b4aPHU13jgnFHvK7g6MDx8nu hpVYZkL/lHj2jLSzdaLHwgMcgj2ubtpypJxh5TxcLyQD/hEXSLCtjuF1bpUEKQ== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1790973800; b=XDdF00O+yaznCL+MOZcpA0XyijezfhFi4G5Z02nZptMHOEk+oUYhttHZwwkoEPu643rZvV OsJLiRxWt4HSvpqF/blxV/QXHw/SgaW2K6oFgYiFE67qniRDjwRq83ehQhDPa/lXoXKcNb +i6lATo2JPY4z1JtEJt5JVo7w23XdkC1W3613QTHne4x2WBOFKqoFAggddFunj0z0scQub k31derrF1sk2oHiiD+FZ06+qn3/PTN+CrmFh4D8W3i7eKc7bNQvvMWfoIR3JPOLmK89C6w PwNVmqsLalFBVz68F0EFZberyaXjtBEVQBOFC+6Rdahp7gvIdSz1lsQTpvKrWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1790973800; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/kSNxjZwbUgsJOIi5EfVqYxOWlxE2byJTOGZToxdVTQ=; b=UVyCersz3hEUWcftpVbGvQbWZk6zJRyS5gxCGlWZ9GOq8Ycz/dsZufpHDnBnN1+EuT3S8F PRJtcjVj+oSA24ZqXpFVSadJlfyE4/szOm9FGOUGpuTN8ErkkA8oE/bcM69JBpYxtNdWjl 4y3snf5/Th3m8a5ae6eqtpReJDLXQsG/LGoXBeIkp5KgQUeAHYvzMI8G6RiLzyQBrApJxy fLgzTtKq/QORuaupOWuwLJDNmqMKiO0RWoTtueMbSr/J8d8m9l+xNaWoD1g0HnhY8SKSRZ kLQqYUZaNNjJUE6KxmsSVc5eJdVqOufJPYgbFFz0O2UTZBH6rJHT+VsKRI8Rig== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hxLMr16W7zbSJ for ; Fri, 02 Oct 2026 20:43:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 38d38 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 02 Oct 2026 20:43:14 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Enji Cooper Subject: git: 9d5a33d9c294 - main - [tests] lib/libc/gen:assert_test: undefine `NDEBUG` List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ngie X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9d5a33d9c294b01cead6ff65b0773b5b5ab85ccd Auto-Submitted: auto-generated Date: Fri, 02 Oct 2026 20:43:14 +0000 Message-Id: <6ac01762.38d38.335153e@gitrepo.freebsd.org> The branch main has been updated by ngie: URL: https://cgit.FreeBSD.org/src/commit/?id=9d5a33d9c294b01cead6ff65b0773b5b5ab85ccd commit 9d5a33d9c294b01cead6ff65b0773b5b5ab85ccd Author: Enji Cooper AuthorDate: 2026-10-02 19:27:51 +0000 Commit: Enji Cooper CommitDate: 2026-10-02 20:42:53 +0000 [tests] lib/libc/gen:assert_test: undefine `NDEBUG` In the event `NDEBUG` was defined, `assert` would become a no-op, breaking some of the expectations in `assert_test` around `assert(..)` failing generating a coredump. This is a better approach than the previous one committed in 6f3445006a as it continues to test the `assert(..)` function instead of just skipping it if `NDEBUG` was defined. Suggested by: kevans MFC after: 4 days MFC with: 6f3445006a Fixes: 6f3445006a Differential Revision: https://reviews.freebsd.org/D60253 --- contrib/netbsd-tests/lib/libc/gen/t_assert.c | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) diff --git a/contrib/netbsd-tests/lib/libc/gen/t_assert.c b/contrib/netbsd-tests/lib/libc/gen/t_assert.c index b4023223b446..cec98c3beed0 100644 --- a/contrib/netbsd-tests/lib/libc/gen/t_assert.c +++ b/contrib/netbsd-tests/lib/libc/gen/t_assert.c @@ -28,6 +28,12 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ + +#if defined(__FreeBSD__) +/* TODO: upstream this. */ +#undef NDEBUG +#endif + #include __RCSID("$NetBSD: t_assert.c,v 1.3 2017/01/10 15:17:57 christos Exp $"); @@ -43,18 +49,6 @@ __RCSID("$NetBSD: t_assert.c,v 1.3 2017/01/10 15:17:57 christos Exp $"); #include #include -#ifdef __FreeBSD__ -/* TODO: upstream this. */ -static void -skip_if_ndebug_set(void) -{ - -#ifdef NDEBUG - atf_tc_skip("Testcase requires code to be compiled without -DNDEBUG."); -#endif -} -#endif - static void disable_corefile(void) { @@ -86,10 +80,6 @@ ATF_TC_BODY(assert_false, tc) pid_t pid; int sta; -#ifdef __FreeBSD__ - skip_if_ndebug_set(); -#endif - pid = fork(); ATF_REQUIRE(pid >= 0); @@ -128,10 +118,6 @@ ATF_TC_BODY(assert_true, tc) pid_t pid; int sta; -#ifdef __FreeBSD__ - skip_if_ndebug_set(); -#endif - pid = fork(); ATF_REQUIRE(pid >= 0);