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] [day] [month] [year] [list]
Message-ID: <CAFo99gaZ52cbLGPT6=fPYydZjm5Jx3KNbwKWoKsgep2DTR8b5Q@mail.gmail.com>
Date:	Sun, 14 Dec 2014 23:55:43 +0100
From:	Rickard Strandqvist <rickard_strandqvist@...ctrumdigital.se>
To:	Joe Perches <joe@...ches.com>
Cc:	Forest Bond <forest@...ttletooquiet.net>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Malcolm Priestley <tvboxspy@...il.com>,
	Guillaume Clement <gclement@...bob.org>,
	Guido Martínez <guido@...guardiasur.com.ar>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
	Himangi Saraogi <himangi774@...il.com>,
	devel@...verdev.osuosl.org,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] staging: vt6655: wmgr.c: Fix for possible null pointer dereference

Hi

Ok, if you want, otherwise we can put it after the NULL check?

Kind regards
Rickard Strandqvist


2014-12-14 23:52 GMT+01:00 Joe Perches <joe@...ches.com>:
> On Sun, 2014-12-14 at 23:42 +0100, Rickard Strandqvist wrote:
>> There is otherwise a risk of a possible null pointer dereference.
>> Was largely found by using a static code analysis program called cppcheck.
> []
>> diff --git a/drivers/staging/vt6655/wmgr.c b/drivers/staging/vt6655/wmgr.c
> []
>> @@ -4391,7 +4391,7 @@ bAdd_PMKID_Candidate(
>>       unsigned int ii = 0;
>>
>>       pr_debug("bAdd_PMKID_Candidate START: (%d)\n",
>> -              (int)pDevice->gsPMKIDCandidate.NumCandidates);
>> +             (int)(pDevice ? pDevice->gsPMKIDCandidate.NumCandidates : 0));
>
> This is a function tracing printk.
> I think it's better to just remove it.
>
>
>
--
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