diff options
author | Eric Paris <eparis@redhat.com> | 2010-11-29 15:47:09 -0500 |
---|---|---|
committer | Eric Paris <eparis@redhat.com> | 2010-11-30 17:28:57 -0500 |
commit | c41ab6a1b9028de33e74101cb0aae13098a56fdb (patch) | |
tree | f56d5af7c2743623018b04b14cc4f47895c3bb3e | |
parent | c9e86a9b95f198d7df49b25fcd808ee39cba218f (diff) | |
download | linux-3.10-c41ab6a1b9028de33e74101cb0aae13098a56fdb.tar.gz linux-3.10-c41ab6a1b9028de33e74101cb0aae13098a56fdb.tar.bz2 linux-3.10-c41ab6a1b9028de33e74101cb0aae13098a56fdb.zip |
flex_array: fix flex_array_put_ptr macro to be valid C
Using flex_array_put_ptr() results in a compile error "error: lvalue
required as unary ‘&’ operand" fix the casting order to fix this.
Signed-off-by: Eric Paris <eparis@redhat.com>
-rw-r--r-- | include/linux/flex_array.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/flex_array.h b/include/linux/flex_array.h index 631b77f2ac7..70e4efabe0f 100644 --- a/include/linux/flex_array.h +++ b/include/linux/flex_array.h @@ -71,7 +71,7 @@ void *flex_array_get(struct flex_array *fa, unsigned int element_nr); int flex_array_shrink(struct flex_array *fa); #define flex_array_put_ptr(fa, nr, src, gfp) \ - flex_array_put(fa, nr, &(void *)(src), gfp) + flex_array_put(fa, nr, (void *)&(src), gfp) void *flex_array_get_ptr(struct flex_array *fa, unsigned int element_nr); |