[Devel] Re: [PATCH 3/7] process.c: use ckpt_err at restart

Oren Laadan orenl at cs.columbia.edu
Mon Nov 16 08:09:14 PST 2009



serue at us.ibm.com wrote:
> From: Serge E. Hallyn <serue at us.ibm.com>
> 
> Signed-off-by: Serge E. Hallyn <serue at us.ibm.com>
> ---
>  checkpoint/process.c |   16 ++++++++--------
>  1 files changed, 8 insertions(+), 8 deletions(-)
> 
> diff --git a/checkpoint/process.c b/checkpoint/process.c
> index 5bc8ccc..9a56f68 100644
> --- a/checkpoint/process.c
> +++ b/checkpoint/process.c
> @@ -581,16 +581,15 @@ static int restore_task_creds(struct ckpt_ctx *ctx)
>  
>  	realcred = ckpt_obj_fetch(ctx, h->cred_ref, CKPT_OBJ_CRED);
>  	if (IS_ERR(realcred)) {
> -		ckpt_debug("Error %ld fetching realcred (ref %d)\n",
> -			PTR_ERR(realcred), h->cred_ref);
>  		ret = PTR_ERR(realcred);
> +		ckpt_err(ctx, ret, "%(O)Error fetching realcred\n",
> +			 h->cred_ref);

Would it make sense to report fetching (and any other object related
generic error) in the original function - in this case ckpt_obj_fetch(),
something like:

	ckpt_err(ctx, ret, "%(O)Error fetching object type %s\n",...)

[...]

Oren.

_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list