Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F115416035
D29752.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
417 B
Referenced Files
None
Subscribers
None
D29752.diff
View Options
diff --git a/sys/kern/subr_sbuf.c b/sys/kern/subr_sbuf.c
--- a/sys/kern/subr_sbuf.c
+++ b/sys/kern/subr_sbuf.c
@@ -266,6 +266,10 @@
KASSERT(error != NULL,
("%s called with NULL error pointer", __func__));
+ if (uio->uio_resid >= INT_MAX || uio->uio_resid < SBUF_MINSIZE - 1) {
+ *error = EINVAL;
+ return (NULL);
+ }
s = sbuf_new(s, NULL, uio->uio_resid + 1, 0);
if (s == NULL) {
*error = ENOMEM;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Apr 24, 2:11 PM (16 h, 20 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
17760363
Default Alt Text
D29752.diff (417 B)
Attached To
Mode
D29752: sbuf_uionew(): sbuf_new() takes int as length
Attached
Detach File
Event Timeline
Log In to Comment