[glibc] elf: Fix elf/tst-bz26577-minstack.c on hurd
Adhemerval Zanella via Glibc-cvs <[email protected]> Thu, 14 May 2026 20:21:23 +0000 (GMT)
| Newsgroups | gmane.comp.lib.glibc.cvs |
|---|---|
| Message-ID | <[email protected]> |
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=785a028ab70da332bf0d573c7fc3d7bb0c4f7273 commit 785a028ab70da332bf0d573c7fc3d7bb0c4f7273 Author: Adhemerval Zanella <[email protected]> Date: Thu May 14 17:20:02 2026 -0300 elf: Fix elf/tst-bz26577-minstack.c on hurd Hurd does not defined PTHREAD_STACK_MIN, use support_small_thread_stack_size instead. Checked on a x86_64-gnu build. Diff: --- elf/tst-bz26577-minstack.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/elf/tst-bz26577-minstack.c b/elf/tst-bz26577-minstack.c index 6b8fa5e9bf..f49011290f 100644 --- a/elf/tst-bz26577-minstack.c +++ b/elf/tst-bz26577-minstack.c @@ -51,10 +51,16 @@ static int do_test (void) { char *path = xasprintf ("%s/elf/tst-bz26577-mod.so", support_objdir_root); + size_t stacksize = +#ifdef PTHREAD_STACK_MIN + PTHREAD_STACK_MIN +#else + support_small_thread_stack_size (); +#endif pthread_attr_t attr; xpthread_attr_init (&attr); - xpthread_attr_setstacksize (&attr, PTHREAD_STACK_MIN); + xpthread_attr_setstacksize (&attr, stacksize); pthread_t thr = xpthread_create (&attr, dlopen_thread, path); xpthread_join (thr); xpthread_attr_destroy (&attr);