From: Alexey Dobriyan <adobriyan@gmail.com>
To: Jani Nikula <ext-jani.1.nikula@nokia.com>
Cc: akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
ext-phil.2.carmody@nokia.com
Subject: Re: [PATCH] err.h: add __must_check to error pointer handlers
Date: Fri, 12 Mar 2010 20:40:56 +0200 [thread overview]
Message-ID: <20100312184056.GA4107@x200> (raw)
In-Reply-To: <1268401540-8994-1-git-send-email-ext-jani.1.nikula@nokia.com>
On Fri, Mar 12, 2010 at 03:45:40PM +0200, Jani Nikula wrote:
> Add __must_check to error pointer handlers to have the compiler warn
> about mistakes like:
>
> if (err)
> ERR_PTR(err);
> -static inline void *ERR_PTR(long error)
> +static inline void * __must_check ERR_PTR(long error)
We had bugs like that?
Pretty much every non-void function should be marked then.
next prev parent reply other threads:[~2010-03-12 18:40 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-12 13:45 Jani Nikula
2010-03-12 18:40 ` Alexey Dobriyan [this message]
2010-03-12 19:45 ` Phil Carmody
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=20100312184056.GA4107@x200 \
--to=adobriyan@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=ext-jani.1.nikula@nokia.com \
--cc=ext-phil.2.carmody@nokia.com \
--cc=linux-kernel@vger.kernel.org \
/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
Powered by JetHome