linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: NeilBrown <neilb@suse.de>
To: Jes.Sorensen@redhat.com
Cc: linux-raid@vger.kernel.org, dledford@redhat.com
Subject: Re: [PATCH 00/12] More leak and NULL pointer dereference fixes
Date: Thu, 3 Nov 2011 08:12:51 +1100	[thread overview]
Message-ID: <20111103081251.517d462a@notabene.brown> (raw)
In-Reply-To: <1320244937-9739-1-git-send-email-Jes.Sorensen@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1809 bytes --]

On Wed,  2 Nov 2011 15:42:05 +0100 Jes.Sorensen@redhat.com wrote:

> From: Jes Sorensen <Jes.Sorensen@redhat.com>
> 
> Hi,
> 
> As promised, here is another batch of fixes for small memory leaks,
> use of invalid file descriptors and NULL pointer dereferences.
> 
> The coverity output is starting to look a lot better by now :)
> 
> Cheers,
> Jes

Thanks.


> 
> 
> Jes Sorensen (12):
>   mdadm: add missing break for UpdateSubarray

This was wasn't correct.  The code was actually doing  the right thing.
But I agree that it looked wrong so I rearranged the code a bit to make it
(hopefully) less confusing.

All the rest applied.

thanks,
NeilBrown



>   ping_monitor(): check file descriptor is valid before using and
>     closing it
>   mdstat_read(): Check return value of dup() before using file
>     descriptor
>   get_component_size(): Check read() return value for error before
>     using it
>   array_try_spare(): open_dev() returns -1 on error, not zero
>   disk_init_and_add(): Fail if opening sysfs file descriptors fail
>   close_aa(): Verify file descriptors are valid before trying to close
>     them
>   ahci_enumerate_ports(): Don't close fd that failed to open
>   unblock_monitor(): Check sra is valid before dereferencing
>   Manage_ro(): Check pointer rather than dereferencing it
>   fd2devname(): Don't dereference NULL pointer
>   match_metadata_desc(): Fix memory leak
> 
>  Incremental.c |    2 +-
>  Manage.c      |    2 +-
>  managemon.c   |   21 ++++++++++++++++-----
>  mdadm.c       |    1 +
>  mdstat.c      |    7 ++++++-
>  msg.c         |   11 +++++++++--
>  super-intel.c |    8 +++++---
>  super-mbr.c   |    7 ++++---
>  sysfs.c       |    2 +-
>  9 files changed, 44 insertions(+), 17 deletions(-)
> 


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

  parent reply	other threads:[~2011-11-02 21:12 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-02 14:42 [PATCH 00/12] More leak and NULL pointer dereference fixes Jes.Sorensen
2011-11-02 14:42 ` [PATCH 01/12] mdadm: add missing break for UpdateSubarray Jes.Sorensen
2011-11-02 14:42 ` [PATCH 02/12] ping_monitor(): check file descriptor is valid before using and closing it Jes.Sorensen
2011-11-02 14:42 ` [PATCH 03/12] mdstat_read(): Check return value of dup() before using file descriptor Jes.Sorensen
2011-11-02 14:42 ` [PATCH 04/12] get_component_size(): Check read() return value for error before using it Jes.Sorensen
2011-11-02 14:42 ` [PATCH 05/12] array_try_spare(): open_dev() returns -1 on error, not zero Jes.Sorensen
2011-11-02 14:42 ` [PATCH 06/12] disk_init_and_add(): Fail if opening sysfs file descriptors fail Jes.Sorensen
2011-11-02 14:42 ` [PATCH 07/12] close_aa(): Verify file descriptors are valid before trying to close them Jes.Sorensen
2011-11-02 14:42 ` [PATCH 08/12] ahci_enumerate_ports(): Don't close fd that failed to open Jes.Sorensen
2011-11-02 14:42 ` [PATCH 09/12] unblock_monitor(): Check sra is valid before dereferencing Jes.Sorensen
2011-11-02 14:42 ` [PATCH 10/12] Manage_ro(): Check pointer rather than dereferencing it Jes.Sorensen
2011-11-02 14:42 ` [PATCH 11/12] fd2devname(): Don't dereference NULL pointer Jes.Sorensen
2011-11-02 14:42 ` [PATCH 12/12] match_metadata_desc(): Fix memory leak Jes.Sorensen
2011-11-02 21:12 ` NeilBrown [this message]
2011-11-03 12:40   ` [PATCH 00/12] More leak and NULL pointer dereference fixes Jes Sorensen

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=20111103081251.517d462a@notabene.brown \
    --to=neilb@suse.de \
    --cc=Jes.Sorensen@redhat.com \
    --cc=dledford@redhat.com \
    --cc=linux-raid@vger.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).