Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F177569569
D41967.1794764550.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
D41967.1794764550.diff
View Options
Index: bin/cat/cat.c
===================================================================
--- bin/cat/cat.c
+++ bin/cat/cat.c
@@ -155,7 +155,7 @@
err(EXIT_FAILURE, "unable to create Casper");
fa = fileargs_cinit(casper, argc, argv, O_RDONLY, 0,
- cap_rights_init(&rights, CAP_READ | CAP_FSTAT | CAP_FCNTL),
+ cap_rights_init(&rights, CAP_READ | CAP_FSTAT | CAP_FCNTL | CAP_SEEK),
FA_OPEN | FA_REALPATH);
if (fa == NULL)
err(EXIT_FAILURE, "unable to create fileargs");
Index: sys/kern/vfs_syscalls.c
===================================================================
--- sys/kern/vfs_syscalls.c
+++ sys/kern/vfs_syscalls.c
@@ -4899,7 +4899,7 @@
len = SSIZE_MAX;
/* Get the file structures for the file descriptors. */
- error = fget_read(td, infd, &cap_read_rights, &infp);
+ error = fget_read(td, infd, &cap_pread_rights, &infp);
if (error != 0)
goto out;
if (infp->f_ops == &badfileops) {
@@ -4910,7 +4910,7 @@
error = EINVAL;
goto out;
}
- error = fget_write(td, outfd, &cap_write_rights, &outfp);
+ error = fget_write(td, outfd, &cap_pwrite_rights, &outfp);
if (error != 0)
goto out;
if (outfp->f_ops == &badfileops) {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Nov 15, 5:42 PM (4 m, 3 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41746257
Default Alt Text
D41967.1794764550.diff (1 KB)
Attached To
Mode
D41967: copy_file_range: fix capabilities premissions
Attached
Detach File
Event Timeline