aboutsummaryrefslogtreecommitdiff
path: root/sys/sys/sockbuf.h
diff options
context:
space:
mode:
authorSimon J. Gerraty <sjg@FreeBSD.org>2015-02-13 23:19:35 +0000
committerSimon J. Gerraty <sjg@FreeBSD.org>2015-02-13 23:19:35 +0000
commitd8337a6b4bb62afbe7874e7bd9348ab434d12bf2 (patch)
tree4852ce68c08f7de34040c98d3895e35b6515eb44 /sys/sys/sockbuf.h
parentc4a0c62ce84e68cfde341efeab302c1f425109ce (diff)
downloadsrc-d8337a6b4bb62afbe7874e7bd9348ab434d12bf2.tar.gz
src-d8337a6b4bb62afbe7874e7bd9348ab434d12bf2.zip
sbspace: size of bleft, mleft must match sockbuf fields to avoid
overflow on amd64 Submitted by: anshukla@juniper.net Obtained from: Juniper Networks
Notes
Notes: svn path=/head/; revision=278729
Diffstat (limited to 'sys/sys/sockbuf.h')
-rw-r--r--sys/sys/sockbuf.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/sys/sockbuf.h b/sys/sys/sockbuf.h
index 5bd9bb556251..0e3e172d63f7 100644
--- a/sys/sys/sockbuf.h
+++ b/sys/sys/sockbuf.h
@@ -212,7 +212,7 @@ sbused(struct sockbuf *sb)
static inline long
sbspace(struct sockbuf *sb)
{
- long bleft, mleft;
+ int bleft, mleft; /* size should match sockbuf fields */
#if 0
SOCKBUF_LOCK_ASSERT(sb);