From 6a54af569ec9ea4c772eabe57d0c50e47019559d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C5=8Dshin?= Date: Fri, 15 Dec 2023 20:19:44 +0000 Subject: [PATCH] Blanket-disable argv[0] tests on linux (#1014) --- test/libc/calls/getprogramexecutablename_test.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/libc/calls/getprogramexecutablename_test.c b/test/libc/calls/getprogramexecutablename_test.c index 8e480f960..3e1f8ad8d 100644 --- a/test/libc/calls/getprogramexecutablename_test.c +++ b/test/libc/calls/getprogramexecutablename_test.c @@ -36,10 +36,11 @@ void SetUpOnce(void) { __attribute__((__constructor__)) static void Child(int argc, char *argv[]) { static bool skiparg0tests; - if (!__program_executable_name && !IsFreebsd() && !IsNetbsd()) { + if (IsLinux()) { + /* see also: https://github.com/jart/cosmopolitan/issues/1014 */ skiparg0tests = true; if (argc < 2) { - fprintf(stderr, "warning: old/no loader; skipping argv[0] tests\n"); + fprintf(stderr, "warning: skipping argv[0] tests\n"); } } if (argc >= 2 && !strcmp(argv[1], "Child")) {