From: Oleg Nesterov <oleg@redhat.com>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: ananth@in.ibm.com, x86@kernel.org, linux-kernel@vger.kernel.org,
srikar@linux.vnet.ibm.com
Subject: Re: [PATCH] uprobes: don't put NULL pointer in uprobe_register()
Date: Fri, 31 Aug 2012 16:05:39 +0200 [thread overview]
Message-ID: <20120831140539.GA18975@redhat.com> (raw)
In-Reply-To: <1346347582-20945-1-git-send-email-bigeasy@linutronix.de>
On 08/30, Sebastian Andrzej Siewior wrote:
>
> alloc_uprobe() might return a NULL pointer, put_uprobe() can't deal with
> this.
>
> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
> ---
> kernel/events/uprobes.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/kernel/events/uprobes.c b/kernel/events/uprobes.c
> index 7b3112c..30f3e23 100644
> --- a/kernel/events/uprobes.c
> +++ b/kernel/events/uprobes.c
> @@ -897,7 +897,8 @@ int uprobe_register(struct inode *inode, loff_t offset, struct uprobe_consumer *
> }
>
> mutex_unlock(uprobes_hash(inode));
> - put_uprobe(uprobe);
> + if (uprobe)
> + put_uprobe(uprobe);
Applied as cf54f5c8, thanks.
Oleg.
next prev parent reply other threads:[~2012-08-31 14:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-30 17:26 [PATCH] uprobes: don't put NULL pointer in uprobe_register() Sebastian Andrzej Siewior
2012-08-31 14:05 ` Oleg Nesterov [this message]
2012-09-12 12:43 ` Srikar Dronamraju
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=20120831140539.GA18975@redhat.com \
--to=oleg@redhat.com \
--cc=ananth@in.ibm.com \
--cc=bigeasy@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=srikar@linux.vnet.ibm.com \
--cc=x86@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
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;
as well as URLs for NNTP newsgroup(s).