From: Roel Kluin <roel.kluin@gmail.com>
To: hjlipp@web.de
Cc: gigaset307x-common@lists.sourceforge.net, netdev@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>
Subject: [PATCH] gigaset: beyond ARRAY_SIZE of iwb->data
Date: Thu, 21 May 2009 22:32:54 +0200 [thread overview]
Message-ID: <4A15BA76.6080007@gmail.com> (raw)
Do not go beyond ARRAY_SIZE of iwb->data
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
Sorry for the dup, the header was incorrect. This is against linux-next.
diff --git a/drivers/isdn/gigaset/isocdata.c b/drivers/isdn/gigaset/isocdata.c
index fbce522..5569a6e 100644
--- a/drivers/isdn/gigaset/isocdata.c
+++ b/drivers/isdn/gigaset/isocdata.c
@@ -177,7 +177,7 @@ int gigaset_isowbuf_getbytes(struct isowbuf_t *iwb, int size)
return -EINVAL;
}
src = iwb->read;
- if (unlikely(limit > BAS_OUTBUFSIZE + BAS_OUTBUFPAD ||
+ if (unlikely(limit >= BAS_OUTBUFSIZE + BAS_OUTBUFPAD ||
(read < src && limit >= src))) {
err("isoc write buffer frame reservation violated");
return -EFAULT;
next reply other threads:[~2009-05-21 20:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-21 20:32 Roel Kluin [this message]
2009-05-21 22:04 ` [PATCH] gigaset: beyond ARRAY_SIZE of iwb->data David Miller
2009-05-25 10:00 ` Tilman Schmidt
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=4A15BA76.6080007@gmail.com \
--to=roel.kluin@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=gigaset307x-common@lists.sourceforge.net \
--cc=hjlipp@web.de \
--cc=netdev@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.