[PATCH] powerpc: Convert tests to the new support test-driver

Florian Weimer fweimer@redhat.com
Mon Dec 19 20:01:00 GMT 2016


On 12/19/2016 07:43 PM, Carlos Eduardo Seo wrote:

>        pthread_attr_destroy (&attr);
>     -  if (pthread_join (threads[i], &status))
>     -    {
>     -      printf ("FAIL: error joining thread %ld.\n", i);
>     -      return 1;
>     -    }
>     +  status = xpthread_join (threads[i]);
>        if (status)
>          {
>            return 1;
>     @@ -184,5 +178,4 @@ do_test (void)
>
> I don’t think you should omit the FAIL message here. Other than that, LGTM.

Right.  I could add a TEST_VERIFY macro which would allow you to write:

   TEST_VERIFY (xpthread_join (threads[i]) != NULL);

or

   TEST_VERIFY_FAIL (xpthread_join (threads[i]) != NULL);

(in case execution is not expected to continue).

Thanks,
Florian



More information about the Libc-alpha mailing list