* [PATCH] ipc: compat_mq sizeof() instead of sizeof
@ 2014-10-02 16:20 Paul McQuade
2014-10-07 20:06 ` Rafael Aquini
0 siblings, 1 reply; 2+ messages in thread
From: Paul McQuade @ 2014-10-02 16:20 UTC (permalink / raw)
To: paulmcquad; +Cc: akpm, heiko.carstens, manfred, aquini, hpa, linux-kernel
added a parenthesis for sizeof function
Signed-off-by: Paul McQuade <paulmcquad@gmail.com>
---
ipc/compat_mq.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/ipc/compat_mq.c b/ipc/compat_mq.c
index ef6f91c..27496d9 100644
--- a/ipc/compat_mq.c
+++ b/ipc/compat_mq.c
@@ -25,7 +25,7 @@ struct compat_mq_attr {
static inline int get_compat_mq_attr(struct mq_attr *attr,
const struct compat_mq_attr __user *uattr)
{
- if (!access_ok(VERIFY_READ, uattr, sizeof *uattr))
+ if (!access_ok(VERIFY_READ, uattr, sizeof(*uattr)))
return -EFAULT;
return __get_user(attr->mq_flags, &uattr->mq_flags)
@@ -37,7 +37,7 @@ static inline int get_compat_mq_attr(struct mq_attr *attr,
static inline int put_compat_mq_attr(const struct mq_attr *attr,
struct compat_mq_attr __user *uattr)
{
- if (clear_user(uattr, sizeof *uattr))
+ if (clear_user(uattr, sizeof(*uattr)))
return -EFAULT;
return __put_user(attr->mq_flags, &uattr->mq_flags)
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ipc: compat_mq sizeof() instead of sizeof
2014-10-02 16:20 [PATCH] ipc: compat_mq sizeof() instead of sizeof Paul McQuade
@ 2014-10-07 20:06 ` Rafael Aquini
0 siblings, 0 replies; 2+ messages in thread
From: Rafael Aquini @ 2014-10-07 20:06 UTC (permalink / raw)
To: Paul McQuade; +Cc: akpm, heiko.carstens, manfred, hpa, linux-kernel
On Thu, Oct 02, 2014 at 05:20:28PM +0100, Paul McQuade wrote:
> added a parenthesis for sizeof function
>
This log message could use some enhancement (just a nit)
Other than that:
Acked-by: Rafael Aquini <aquini@redhat.com>
> Signed-off-by: Paul McQuade <paulmcquad@gmail.com>
> ---
> ipc/compat_mq.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/ipc/compat_mq.c b/ipc/compat_mq.c
> index ef6f91c..27496d9 100644
> --- a/ipc/compat_mq.c
> +++ b/ipc/compat_mq.c
> @@ -25,7 +25,7 @@ struct compat_mq_attr {
> static inline int get_compat_mq_attr(struct mq_attr *attr,
> const struct compat_mq_attr __user *uattr)
> {
> - if (!access_ok(VERIFY_READ, uattr, sizeof *uattr))
> + if (!access_ok(VERIFY_READ, uattr, sizeof(*uattr)))
> return -EFAULT;
>
> return __get_user(attr->mq_flags, &uattr->mq_flags)
> @@ -37,7 +37,7 @@ static inline int get_compat_mq_attr(struct mq_attr *attr,
> static inline int put_compat_mq_attr(const struct mq_attr *attr,
> struct compat_mq_attr __user *uattr)
> {
> - if (clear_user(uattr, sizeof *uattr))
> + if (clear_user(uattr, sizeof(*uattr)))
> return -EFAULT;
>
> return __put_user(attr->mq_flags, &uattr->mq_flags)
> --
> 1.9.1
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-10-07 20:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-02 16:20 [PATCH] ipc: compat_mq sizeof() instead of sizeof Paul McQuade
2014-10-07 20:06 ` Rafael Aquini
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).