cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Fabio M. Di Nitto <fdinitto@redhat.com>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] [PATCH 5/5] rgmanager: Fix a possible NULL pointer dereference
Date: Wed, 04 Jul 2012 13:07:17 +0200	[thread overview]
Message-ID: <4FF423E5.8010508@redhat.com> (raw)
In-Reply-To: <20120628195810.GA80026@redhat.com>

ACK

On 6/28/2012 9:58 PM, Ryan McCabe wrote:
> Fix a NULL pointer dereference that could happen when cman_get_node_count()
> returns 0 with errno set to EINTR.
> 
> Possibly resolves rhbz#820632
> 
> Signed-off-by: Ryan McCabe <rmccabe@redhat.com>
> ---
>  rgmanager/src/clulib/members.c |    4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/rgmanager/src/clulib/members.c b/rgmanager/src/clulib/members.c
> index f705297..72f4529 100644
> --- a/rgmanager/src/clulib/members.c
> +++ b/rgmanager/src/clulib/members.c
> @@ -367,8 +367,10 @@ get_member_list(cman_handle_t h)
>  
>  	do {	
>  		++tries;
> -		if (nodes)
> +		if (nodes) {
>  			free(nodes);
> +			nodes = NULL;
> +		}
>  
>  		c = cman_get_node_count(h);
>  		if (c <= 0) {
> 




      reply	other threads:[~2012-07-04 11:07 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-28 19:58 [Cluster-devel] [PATCH 5/5] rgmanager: Fix a possible NULL pointer dereference Ryan McCabe
2012-07-04 11:07 ` Fabio M. Di Nitto [this message]

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=4FF423E5.8010508@redhat.com \
    --to=fdinitto@redhat.com \
    /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).