At Thu,  7 Aug 2014 12:08:23 +0800,
Ruoyu wrote:
> 
> The purpose of the checking in the function is to ensure the
> argument is not null. But it is not needed any longer because
> the argument should be guaranteed in the framework as long as
> CMD_NEED_ARG is specified in subcommand.
> 
> Since the problem is solved in commit e6d1706, we can remove
> the checking safely.
> 
> Signed-off-by: Ruoyu <[email protected]>
> ---
>  dog/node.c | 8 --------
>  1 file changed, 8 deletions(-)

Applied, thanks.
Hitoshi

> 
> diff --git a/dog/node.c b/dog/node.c
> index b6fd929..f9f7351 100644
> --- a/dog/node.c
> +++ b/dog/node.c
> @@ -441,14 +441,6 @@ static int do_plug_unplug(char *disks, bool plug)
>       struct sd_rsp *rsp = (struct sd_rsp *)&hdr;
>       int ret;
>  
> -     if (!disks)
> -             return EXIT_USAGE;
> -
> -     if (!strlen(disks)) {
> -             sd_err("Empty path isn't allowed");
> -             return EXIT_FAILURE;
> -     }
> -
>       if (plug)
>               sd_init_req(&hdr, SD_OP_MD_PLUG);
>       else
> -- 
> 1.8.3.2
> 
> 
> -- 
> sheepdog mailing list
> [email protected]
> http://lists.wpkg.org/mailman/listinfo/sheepdog
-- 
sheepdog mailing list
[email protected]
http://lists.wpkg.org/mailman/listinfo/sheepdog

Reply via email to