All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Dave Jones <davej@redhat.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>, linux-pci@vger.kernel.org
Subject: Re: [scan-admin@coverity.com: New Defects reported by Coverity Scan for Linux]
Date: Thu, 23 Jan 2014 11:55:59 -0800	[thread overview]
Message-ID: <20140123195559.GA12053@kroah.com> (raw)
In-Reply-To: <20140123194631.GA9269@redhat.com>

On Thu, Jan 23, 2014 at 02:46:31PM -0500, Dave Jones wrote:
> On Thu, Jan 23, 2014 at 11:34:05AM -0800, Greg Kroah-Hartman wrote:
>  > On Thu, Jan 23, 2014 at 11:42:46AM -0700, Bjorn Helgaas wrote:
>  > > FYI.  I think the first two (related to "name") are valid.  I haven't
>  > > figured out the "msi_attrs" one yet.
>  > 
>  > I've send a fix for the first two to you now, that should resolve this
>  > issue.
>  > 
>  > But the last one, I can't figure out either.  I think Coverity doesn't
>  > realize that we saved off the pointer and can get back to it later on,
>  > as it's a non-trivial pointer chain involved here.
> 
> This is in the error path though, where we're tearing down all that stuff
> we just built up, so there is no 'later on' afaict.  If we took one of the
> error_* branches, we're not storing this for anything to free later.
> 
> I've only looked at this quickly, but it looks valid to me.
> 
> it looks like we're freeing the contents of the array, but not the array itself.

Doh, you are right, I missed that, thanks, I'll go send a fix for this.

greg k-h

      reply	other threads:[~2014-01-23 19:55 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-23 18:42 [scan-admin@coverity.com: New Defects reported by Coverity Scan for Linux] Bjorn Helgaas
2014-01-23 19:15 ` Greg Kroah-Hartman
2014-01-23 19:30 ` [PATCH] PCI: msi: properly check return value of kmalloc Greg Kroah-Hartman
2014-01-23 20:01   ` [PATCH] PCI: msi: properly free memory on an error path Greg Kroah-Hartman
2014-01-23 20:07     ` Dave Jones
2014-01-29 20:56     ` Bjorn Helgaas
2014-01-29 20:56   ` [PATCH] PCI: msi: properly check return value of kmalloc Bjorn Helgaas
2014-01-23 19:34 ` [scan-admin@coverity.com: New Defects reported by Coverity Scan for Linux] Greg Kroah-Hartman
2014-01-23 19:46   ` Dave Jones
2014-01-23 19:55     ` Greg Kroah-Hartman [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=20140123195559.GA12053@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=bhelgaas@google.com \
    --cc=davej@redhat.com \
    --cc=linux-pci@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.