From: Florin Malita <fmalita@gmail.com>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: akpm@osdl.org, linville@tuxdriver.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] airo.c: check returned values
Date: Mon, 06 Nov 2006 09:30:36 -0500 [thread overview]
Message-ID: <454F470C.2050407@gmail.com> (raw)
In-Reply-To: <454EEAEB.5030606@pobox.com>
Jeff Garzik wrote:
> Florin Malita wrote:
>
>> create_proc_entry() can fail and return NULL in setup_proc_entry(), the
>> result must be checked before dereferencing. (Coverity ID 1443)
>>
>> init_wifidev() & setup_proc_entry() can also fail in _init_airo_card().
>>
>> This adds the checks & cleanup code and removes some whitespace.
>>
>> Signed-off-by: Florin Malita <fmalita@gmail.com>
>>
>
> NAK: create_proc_entry() is complicated. You are correct it can fail
> -- but to add to the confusion, when CONFIG_PROC_FS is disabled, the
> wrapper will also return NULL -- which is NOT a failure case.
>
It is a failure condition for setup_proc_entry() but you're saying that
shouldn't cause a failure of _init_airo_card() as the driver would be
working fine even without procfs support, right?
Note that previously the no-procfs case was *really* broken (it would
explode right away in setup_proc_entry) and I'm not sure it can function
correctly without it now but I guess it's worth a try.
Which one would be preferred:
a) make the setup_proc_entry() call in _init_airo_card() conditional on
CONFIG_PROC_FS
b) simply ignore the result
---
fm
prev parent reply other threads:[~2006-11-06 14:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-10 20:46 [PATCH] airo.c: check returned values Florin Malita
2006-11-06 7:57 ` Jeff Garzik
2006-11-06 14:30 ` Florin Malita [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=454F470C.2050407@gmail.com \
--to=fmalita@gmail.com \
--cc=akpm@osdl.org \
--cc=jgarzik@pobox.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linville@tuxdriver.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox