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: <2f89-5f6b7800-e1-5029548@258698125>
Date:   Wed, 23 Sep 2020 18:28:52 +0200
From:   "Kars Mulder" <kerneldev@...smulder.nl>
To:     "Pavel Machek" <pavel@...x.de>
Cc:     gregkh@...uxfoundation.org, stern@...land.harvard.edu,
        kai.heng.feng@...onical.com, johan@...nel.org,
        tomasz@...esinski.eu, jonathan@...ox.net,
        linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] USB: quirks: simplify quirk handling.

On Monday, September 21, 2020 13:30 CEST, Pavel Machek <pavel@...x.de> wrote: 
> Simplify quirk handling.

This patch seems to contain two different "simplifications" in one.
I have no objections against the first simplification:

-	if (quirk_list) {
-		kfree(quirk_list);
-		quirk_list = NULL;
-	}
-
+	kfree(quirk_list);
 	quirk_list = kcalloc(quirk_count, sizeof(struct quirk_entry),
 			     GFP_KERNEL);

Since kfree() does nothing to nullpointers, all lines that are cut seem
to be superfluous.

The second simplification does not seem to introduce any new bugs as far
as I can tell. Due to lack of experience, I shall refrain from commenting
on whether or not it simplifies things.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ