From: Pekka Enberg <penberg@kernel.org>
To: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Cc: Anton Vorontsov <anton.vorontsov@linaro.org>, linux-mm@kvack.org
Subject: Re: [PATCH 1/2] vmevent: don't leak unitialized data to userspace
Date: Fri, 25 May 2012 10:17:16 +0300 (EEST) [thread overview]
Message-ID: <alpine.LFD.2.02.1205251017090.3897@tux.localdomain> (raw)
In-Reply-To: <201205230927.58802.b.zolnierkie@samsung.com>
On Wed, 23 May 2012, Bartlomiej Zolnierkiewicz wrote:
> From: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
> Subject: [PATCH] vmevent: don't leak unitialized data to userspace
>
> Remember to initialize all attrs[nr] fields in vmevent_setup_watch().
>
> Cc: Anton Vorontsov <anton.vorontsov@linaro.org>
> Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> ---
> mm/vmevent.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> Index: b/mm/vmevent.c
> ===================================================================
> --- a/mm/vmevent.c 2012-05-22 17:51:13.195231958 +0200
> +++ b/mm/vmevent.c 2012-05-22 17:51:40.991231956 +0200
> @@ -350,7 +350,10 @@
>
> attrs = new;
>
> - attrs[nr++].type = attr->type;
> + attrs[nr].type = attr->type;
> + attrs[nr].value = 0;
> + attrs[nr].state = 0;
> + nr++;
> }
>
> watch->sample_attrs = attrs;
Applied, thanks!
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
prev parent reply other threads:[~2012-05-25 7:17 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-23 7:27 [PATCH 1/2] vmevent: don't leak unitialized data to userspace Bartlomiej Zolnierkiewicz
2012-05-25 7:17 ` Pekka Enberg [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=alpine.LFD.2.02.1205251017090.3897@tux.localdomain \
--to=penberg@kernel.org \
--cc=anton.vorontsov@linaro.org \
--cc=b.zolnierkie@samsung.com \
--cc=linux-mm@kvack.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;
as well as URLs for NNTP newsgroup(s).