[20/20] Fix stdlib/test-dlclose-exit-race to not hang

Message ID 13228392bd2974aa35a986b247825723216bd8e7.1666877952.git.szabolcs.nagy@arm.com
State New
Headers
Series patches from the morello port |

Checks

Context Check Description
dj/TryBot-apply_patch success Patch applied to master at the time it was sent
dj/TryBot-32bit success Build for i686

Commit Message

Szabolcs Nagy Oct. 27, 2022, 3:34 p.m. UTC
  Use the standard wrapper that kills the test after a timeout.
---
 stdlib/test-dlclose-exit-race.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
  

Comments

Florian Weimer Oct. 27, 2022, 4:22 p.m. UTC | #1
* Szabolcs Nagy via Libc-alpha:

> Use the standard wrapper that kills the test after a timeout.
> ---
>  stdlib/test-dlclose-exit-race.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/stdlib/test-dlclose-exit-race.c b/stdlib/test-dlclose-exit-race.c
> index 91613116bb..260f7c9e05 100644
> --- a/stdlib/test-dlclose-exit-race.c
> +++ b/stdlib/test-dlclose-exit-race.c
> @@ -63,7 +63,7 @@ last (void)
>  }
>  
>  int
> -main (void)
> +do_test (void)
>  {
>    int value;
>    void *dso;
> @@ -90,3 +90,5 @@ main (void)
>  
>    FAIL_EXIT1 ("Did not terminate via exit(0) in exit_thread() as expected.");
>  }
> +
> +#include <support/test-driver.c>

I'm wondering if this interferes with the text objective.  Unfortunately
this wasn't discussed during the original patch review.

Thanks,
Florian
  

Patch

diff --git a/stdlib/test-dlclose-exit-race.c b/stdlib/test-dlclose-exit-race.c
index 91613116bb..260f7c9e05 100644
--- a/stdlib/test-dlclose-exit-race.c
+++ b/stdlib/test-dlclose-exit-race.c
@@ -63,7 +63,7 @@  last (void)
 }
 
 int
-main (void)
+do_test (void)
 {
   int value;
   void *dso;
@@ -90,3 +90,5 @@  main (void)
 
   FAIL_EXIT1 ("Did not terminate via exit(0) in exit_thread() as expected.");
 }
+
+#include <support/test-driver.c>