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>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080821200441.GA18318@suse.de>
Date:	Thu, 21 Aug 2008 13:04:41 -0700
From:	Greg KH <gregkh@...e.de>
To:	David Brownell <david-b@...bell.net>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 06/15] driver model: anti-oopsing medicine

On Thu, Aug 21, 2008 at 11:24:22AM -0700, David Brownell wrote:
> On Thursday 21 August 2008, Greg Kroah-Hartman wrote:
> > +       if (!class->p) {
> > +               WARN(1, "%s called for class '%s' before it was initialized",
> > +                    __func__, class->name);
> > +               return -EINVAL;
> > +       }
> 
> Or -- for future reference -- using WARN() with non-constant
> initial parameter:
> 
> 	if (WARN(!class-p, "%s called ...\n" ...))
> 		return -EINVAL;
> 
> Some of those macros now have return values, supportin C code
> that looks a bit more compact.

Ah, yeah, that looks much nicer, I'll remember that in the future.

thanks,

greg k-h
--
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