lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJn8CcFE8v8PVkxdsfwi4=f=pVjK6R6uLAs68CtCmv2GU+7b4g@mail.gmail.com>
Date:	Tue, 23 Jul 2013 05:31:21 +0800
From:	Xiaotian Feng <xtfeng@...il.com>
To:	Tejun Heo <tj@...nel.org>
Cc:	Alexander Gordeev <agordeev@...hat.com>, linux-ide@...r.kernel.org,
	linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] AHCI: fix Null pointer dereference in achi_host_active()

On Tue, Jul 23, 2013 at 5:28 AM, Tejun Heo <tj@...nel.org> wrote:
> Hello, Xiaotian.
>
> Thanks for the fix.  A couple comments below.
>
> On Wed, Jul 17, 2013 at 02:10:39PM +0800, Xiaotian Feng wrote:
>>       for (i = 0; i < host->n_ports; i++) {
>>               struct ahci_port_priv *pp = host->ports[i]->private_data;
>> +             const char *desc;
>>
>> +             if (ata_port_is_dummy(host->ports[i]))
>> +                     desc = dev_driver_string(host->dev);
>> +             else
>> +                     desc = pp->irq_desc;
>
> I think it'd be better to branch on pp.  ie. do "if (pp) desc =
> pp->... " instead and then add a comment saying "pp is NULL for
> dummies".
>

Okay, I'll update v2 patch, thanks :)

> Thanks!
>
> --
> tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ