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 for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Date:	Fri, 30 Aug 2013 13:35:33 +0200
From:	Pavel Machek <pavel@....cz>
To:	Sebastian Capella <sebastian.capella@...aro.org>
Cc:	linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
	linux-pm@...r.kernel.org, linaro-dev@...ts.linaro.org,
	len.brown@...el.com, rjw@...k.pl
Subject: Re: [PATCH RFC 1/2] PM / Hibernate: use name_to_dev_t to parse
 resume

On Mon 2013-08-26 10:40:50, Sebastian Capella wrote:
> Apologies for my previous top post reply...
> 
> Quoting Pavel Machek (2013-08-25 08:38:11)
> > Is the allocation actually neccessary? At the very least this should
> > test for NULL...
> 
> 
> Thanks Pavel!  I'll add the check for NULL.
> 
> name_to_dev_t expects a non-const name, but the buffer passed in
> is const.  I also am removing the '\n' if found at the end of the
> string which would violate the const.

Fix name_to_dev_t, then. No need to do memory allocation just to work
around const.

[You can also take a look why it is const in the first place. I don't
think it needs to be.]

									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
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