From: Andrew Morton <akpm@linux-foundation.org>
To: Luis Henriques <luis.henriques@canonical.com>
Cc: linux-kernel@vger.kernel.org, Al Viro <viro@zeniv.linux.org.uk>
Subject: Re: [PATCH] acct: fix build warning when ACCT_VERSION != 3
Date: Thu, 2 Oct 2014 14:09:45 -0700 [thread overview]
Message-ID: <20141002140945.6f8ea8fcad9649819cb457e5@linux-foundation.org> (raw)
In-Reply-To: <20141001230653.GA25541@hercules>
On Thu, 2 Oct 2014 00:06:53 +0100 Luis Henriques <luis.henriques@canonical.com> wrote:
> struct pid_namespace *ns is used only when ACCT_VERSION is 3.
>
> kernel/acct.c:475:24: warning: unused variable 'ns' [-Wunused-variable]
>
> Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
> ---
> kernel/acct.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/kernel/acct.c b/kernel/acct.c
> index b4c667d22e79..5f277f5c5e29 100644
> --- a/kernel/acct.c
> +++ b/kernel/acct.c
> @@ -472,7 +472,9 @@ static void do_acct_process(struct bsd_acct_struct *acct)
> acct_t ac;
> unsigned long flim;
> const struct cred *orig_cred;
> +#if ACCT_VERSION == 3
> struct pid_namespace *ns = acct->ns;
> +#endif
> struct file *file = acct->file;
>
> /*
It's always a good idea to check linux-next. This has been addressed by
http://ozlabs.org/~akpm/mmots/broken-out/acct-eliminate-compile-warning.patch
http://ozlabs.org/~akpm/mmots/broken-out/acct-eliminate-compile-warning-fix.patch
next prev parent reply other threads:[~2014-10-02 21:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-01 23:06 Luis Henriques
2014-10-02 21:09 ` Andrew Morton [this message]
2014-10-02 21:55 ` Luis Henriques
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20141002140945.6f8ea8fcad9649819cb457e5@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luis.henriques@canonical.com \
--cc=viro@zeniv.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome