linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Al Viro <viro@ftp.linux.org.uk>
To: Reinette Chatre <reinette.chatre@intel.com>
Cc: linville@tuxdriver.com, linux-wireless@vger.kernel.org,
	yi.zhu@intel.com, viro@zeniv.linux.org.uk
Subject: Re: [PATCH] ipw2200: prevent alloc of unspecified size on stack
Date: Wed, 19 Dec 2007 06:35:26 +0000	[thread overview]
Message-ID: <20071219063526.GH8181@ftp.linux.org.uk> (raw)
In-Reply-To: <1198044062-25201-1-git-send-email-reinette.chatre@intel.com>

On Tue, Dec 18, 2007 at 10:01:02PM -0800, Reinette Chatre wrote:
> +	/* not using min() because of its strict type checking */
> +	log_size = sizeof(*log) * log_len < PAGE_SIZE ?

		   PAGE_SIZE / sizeof(*log) > len ?

to be provably safe against wraparounds, if you really want to limit that
to PAGE_SIZE...

  parent reply	other threads:[~2007-12-19  6:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-19  6:01 [PATCH] ipw2200: prevent alloc of unspecified size on stack Reinette Chatre
2007-12-19  6:20 ` Zhu Yi
2007-12-19  6:35 ` Al Viro [this message]
2007-12-19  6:52   ` Chatre, Reinette
2007-12-19  7:16   ` Zhu Yi

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=20071219063526.GH8181@ftp.linux.org.uk \
    --to=viro@ftp.linux.org.uk \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=reinette.chatre@intel.com \
    --cc=viro@zeniv.linux.org.uk \
    --cc=yi.zhu@intel.com \
    /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).