Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F137845839
D8657.id22644.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
655 B
Referenced Files
None
Subscribers
None
D8657.id22644.diff
View Options
Index: head/lib/libcapsicum/capsicum_helpers.h
===================================================================
--- head/lib/libcapsicum/capsicum_helpers.h
+++ head/lib/libcapsicum/capsicum_helpers.h
@@ -94,12 +94,12 @@
static __inline int
caph_limit_stdio(void)
{
+ const int iebadf = CAPH_IGNORE_EBADF;
- if (caph_limit_stdin() == -1 || caph_limit_stdout() == -1 ||
- caph_limit_stderr() == -1) {
+ if (caph_limit_stream(STDIN_FILENO, CAPH_READ | iebadf) == -1 ||
+ caph_limit_stream(STDOUT_FILENO, CAPH_WRITE | iebadf) == -1 ||
+ caph_limit_stream(STDERR_FILENO, CAPH_WRITE | iebadf) == -1)
return (-1);
- }
-
return (0);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Nov 27, 9:15 AM (12 h, 39 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26251611
Default Alt Text
D8657.id22644.diff (655 B)
Attached To
Mode
D8657: capsicum_helpers: Squash errors from closed fds
Attached
Detach File
Event Timeline
Log In to Comment