netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: error27@gmail.com
Cc: netdev@vger.kernel.org, chaithrika@ti.com, srk@ti.com,
	khilman@deeprootsystems.com, anantgole@ti.com,
	kernel-janitors@vger.kernel.org
Subject: Re: [patch] davinci_emac: off by one
Date: Wed, 03 Mar 2010 01:08:14 -0800 (PST)	[thread overview]
Message-ID: <20100303.010814.246406195.davem@davemloft.net> (raw)
In-Reply-To: <20100303070724.GC5086@bicker>

From: Dan Carpenter <error27@gmail.com>
Date: Wed, 3 Mar 2010 10:07:24 +0300

> This off by one error was found by smatch.
> 
> drivers/net/davinci_emac.c +2390 emac_dev_open(13) error: buffer overflow 'priv->mac_addr' 6 <= 6
> 
> Signed-off-by: Dan Carpenter <error27@gmail.com>
> ---
> I don't have the hardware to test this.  If would be cool if someone
> would verify that the hardware still works after the patch is applied.

It looks obvious enough for me, taking in more than 6 address
bytes make no sense in an ethernet driver, so I'll apply this.

Thanks.

      reply	other threads:[~2010-03-03  9:07 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-03  7:07 [patch] davinci_emac: off by one Dan Carpenter
2010-03-03  9:08 ` David Miller [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=20100303.010814.246406195.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=anantgole@ti.com \
    --cc=chaithrika@ti.com \
    --cc=error27@gmail.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=khilman@deeprootsystems.com \
    --cc=netdev@vger.kernel.org \
    --cc=srk@ti.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).