[CRIU] Re: [PATCH 2/6] parasite: Dump blocked thread signals mask

Pavel Emelyanov xemul at parallels.com
Thu Nov 1 06:59:10 EDT 2012


On 10/31/2012 02:44 PM, Cyrill Gorcunov wrote:
> ---
>  include/parasite.h |    1 +
>  parasite.c         |    8 ++++++--
>  2 files changed, 7 insertions(+), 2 deletions(-)
> 

> @@ -354,11 +354,15 @@ static int dump_thread_info(struct parasite_dump_thread_info *args)
>  
>  	ret = sys_prctl(PR_GET_TID_ADDRESS, (unsigned long) &args->tid_addr, 0, 0, 0);
>  	if (ret)
> -		return ret;
> +		goto err;
>  
>  	args->tid = sys_gettid();
>  
> -	return 0;
> +	ksigfillset(&args->blocked);
> +	ret = sys_sigprocmask(SIG_SETMASK, NULL, &args->blocked, sizeof(k_rtsigset_t));
> +
> +err:
> +	return ret;
>  }
>  
>  static int drain_fds(struct parasite_drain_fd *args)

No, this is wrong. Threads' blocked signals should be handled the same way as
tasks' are.


More information about the CRIU mailing list