detecting hibernation capability
David Zeuthen
david at fubar.dk
Thu Dec 1 08:48:17 PST 2005
On Wed, 2005-11-30 at 17:16 +0000, Richard Hughes wrote:
> Thanks Joe. New patch attached.
Thanks, looks correct, only a few style comments:
+ if (!fp) {
I know many people do this, but, really, fp is not a boolean, it's a
pointer and you want to test whether it's NULL so do use (fp == NULL)
instead. Ditto use (poweroptions != NULL). Be explicit
+ return;
Please use the "goto out" pattern for error handling. Also, ideally you
should use
void *foo;
foo = NULL;
instead of
void *foo = NULL;
Cheers,
David
More information about the hal
mailing list