Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F173725029
D5588.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
568 B
Referenced Files
None
Subscribers
None
D5588.diff
View Options
Index: libprocstat.c
===================================================================
--- libprocstat.c
+++ libprocstat.c
@@ -2494,6 +2494,8 @@
}
if (error == -1)
return (NULL);
+ if (len <= SIZE_T_MAX / 2)
+ len *= 2; /* allow for rapid thread creation */
kkstp = malloc(len);
if (kkstp == NULL) {
warn("malloc(%zu)", len);
@@ -2500,7 +2502,7 @@
return (NULL);
}
if (sysctl(name, 4, kkstp, &len, NULL, 0) == -1) {
- warn("sysctl: kern.proc.pid: %d", pid);
+ warn("sysctl: kern.proc.kstack: %d", pid);
free(kkstp);
return (NULL);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Sep 28, 11:30 PM (1 h, 34 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
39841957
Default Alt Text
D5588.diff (568 B)
Attached To
Mode
D5588: libprocstat: handle race condition while retrieving thread kernel stacks
Attached
Detach File
Event Timeline
Log In to Comment