Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 198276
b: refs/heads/master
c: e47103b
h: refs/heads/master
v: v3
  • Loading branch information
Jani Nikula authored and Linus Torvalds committed May 25, 2010
1 parent 3c704d2 commit 33324ce
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1f85f87d4f81d1e5a2d502d48316a1bdc5acac0b
refs/heads/master: e47103b1af5df52fa69e18b14d3012472f78817d
10 changes: 5 additions & 5 deletions trunk/include/linux/err.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@

#define IS_ERR_VALUE(x) unlikely((x) >= (unsigned long)-MAX_ERRNO)

static inline void *ERR_PTR(long error)
static inline void * __must_check ERR_PTR(long error)
{
return (void *) error;
}

static inline long PTR_ERR(const void *ptr)
static inline long __must_check PTR_ERR(const void *ptr)
{
return (long) ptr;
}

static inline long IS_ERR(const void *ptr)
static inline long __must_check IS_ERR(const void *ptr)
{
return IS_ERR_VALUE((unsigned long)ptr);
}

static inline long IS_ERR_OR_NULL(const void *ptr)
static inline long __must_check IS_ERR_OR_NULL(const void *ptr)
{
return !ptr || IS_ERR_VALUE((unsigned long)ptr);
}
Expand All @@ -46,7 +46,7 @@ static inline long IS_ERR_OR_NULL(const void *ptr)
* Explicitly cast an error-valued pointer to another pointer type in such a
* way as to make it clear that's what's going on.
*/
static inline void *ERR_CAST(const void *ptr)
static inline void * __must_check ERR_CAST(const void *ptr)
{
/* cast away the const */
return (void *) ptr;
Expand Down

0 comments on commit 33324ce

Please sign in to comment.