From: "Ola N. Kaldestad" <mail@okal.no> To: keescook@chromium.org Cc: mcgrof@kernel.org, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, "Ola N. Kaldestad" <mail@okal.no> Subject: [PATCH] Fix code-style warning Date: Thu, 9 Nov 2017 15:40:35 +0100 Message-ID: <1510238435-1655-1-git-send-email-mail@okal.no> (raw) Removed unnecessary else block, and removed redundant return and call to kfree in if block. Signed-off-by: Ola N. Kaldestad <mail@okal.no> --- kernel/sysctl.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/kernel/sysctl.c b/kernel/sysctl.c index d9c31bc..87fbb3e 100644 --- a/kernel/sysctl.c +++ b/kernel/sysctl.c @@ -3089,14 +3089,12 @@ int proc_do_large_bitmap(struct ctl_table *table, int write, else bitmap_copy(bitmap, tmp_bitmap, bitmap_len); } - kfree(tmp_bitmap); *lenp -= left; *ppos += *lenp; - return 0; - } else { - kfree(tmp_bitmap); - return err; } + + kfree(tmp_bitmap); + return err; } #else /* CONFIG_PROC_SYSCTL */ -- 2.7.4
next reply index Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2017-11-09 14:40 Ola N. Kaldestad [this message] [not found] <20171113232654.9473-1-mail@okal.no> 2017-11-13 23:41 ` [PATCH] Fix: " Kees Cook
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=1510238435-1655-1-git-send-email-mail@okal.no \ --to=mail@okal.no \ --cc=keescook@chromium.org \ --cc=linux-fsdevel@vger.kernel.org \ --cc=linux-kernel@vger.kernel.org \ --cc=mcgrof@kernel.org \ /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
Linux-Fsdevel Archive on lore.kernel.org Archives are clonable: git clone --mirror https://lore.kernel.org/linux-fsdevel/0 linux-fsdevel/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 linux-fsdevel linux-fsdevel/ https://lore.kernel.org/linux-fsdevel \ linux-fsdevel@vger.kernel.org public-inbox-index linux-fsdevel Example config snippet for mirrors Newsgroup available over NNTP: nntp://nntp.lore.kernel.org/org.kernel.vger.linux-fsdevel AGPL code for this site: git clone https://public-inbox.org/public-inbox.git