[CRIU] [PATCH 5/9] zdtm: pthread00 -- Fail if subthread can't be created
Andrew Vagin
avagin at parallels.com
Fri Nov 23 09:18:58 EST 2012
On Fri, Nov 23, 2012 at 04:50:56PM +0400, Cyrill Gorcunov wrote:
>
> Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
> ---
> test/zdtm/live/static/pthread00.c | 6 ++++--
> 1 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/test/zdtm/live/static/pthread00.c b/test/zdtm/live/static/pthread00.c
> index 384e0d5..38dad67 100644
> --- a/test/zdtm/live/static/pthread00.c
> +++ b/test/zdtm/live/static/pthread00.c
> @@ -104,8 +104,10 @@ static void *thread_func_1(void *map)
>
> memcpy(tls_data, __tls_data, sizeof(tls_data));
>
> - if (pthread_create(&th, NULL, &thread_subfunc_1, map))
> - perror("Cant create thread");
> + if (pthread_create(&th, NULL, &thread_subfunc_1, map)) {
> + fail("Can't pthread_create");
> + exit(1);
You wanna to say exit_group...
> + }
>
> pid = test_fork();
> if (pid < 0) {
More information about the CRIU
mailing list