lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <47C51566.1070104@cn.fujitsu.com>
Date:	Wed, 27 Feb 2008 15:46:46 +0800
From:	Li Zefan <lizf@...fujitsu.com>
To:	Paul Jackson <pj@....com>
CC:	akpm@...ux-foundation.org, linux-kernel@...r.kernel.org,
	Paul Menage <menage@...gle.com>
Subject: Re: [PATCH] cpuset: fix return value of cpuset_populate()

Paul Jackson wrote:
> [Resending a patch that Li Zefan just sent, adding the other Paul (Menage)
>  to the CC list.  -pj]
> 

Thanks, I should have CCed Menage. :)

> - no need to check err == 0
> - the last return value of cgroup_add_file() is ignored
> 
> Signed-off-by: Li Zefan <lizf@...fujitsu.com>
> ---
>  kernel/cpuset.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/kernel/cpuset.c b/kernel/cpuset.c
> index 3e296ed..1c5b2d2 100644
> --- a/kernel/cpuset.c
> +++ b/kernel/cpuset.c
> @@ -1482,10 +1482,10 @@ static int cpuset_populate(struct cgroup_subsys *ss, struct cgroup *cont)
>  	if ((err = cgroup_add_file(cont, ss, &cft_spread_slab)) < 0)
>  		return err;
>  	/* memory_pressure_enabled is in root cpuset only */
> -	if (err == 0 && !cont->parent)
> +	if (!cont->parent)
>  		err = cgroup_add_file(cont, ss,
>  					 &cft_memory_pressure_enabled);
> -	return 0;
> +	return err;
>  }
>  
>  /*
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ