Check if QubesIncoming filesystem supports O_TMPFILE
The filesystem hosting ~/QubesIncoming/srcVM/ needs to support O_TMPFILE too, in addition to the kernel. If it doesn't, take the use_tmpfile = 0 fallback.
This commit is contained in:
parent
5b250eb279
commit
74a1b4cc50
@ -112,8 +112,8 @@ void process_one_file_reg(struct file_header *untrusted_hdr,
|
||||
if (use_tmpfile) {
|
||||
fdout = open(".", O_WRONLY | O_TMPFILE, 0700);
|
||||
if (fdout < 0) {
|
||||
if (errno==ENOENT)
|
||||
/* if it fails, do not attempt further use - most likely kernel too old */
|
||||
if (errno==ENOENT || /* most likely, kernel too old for O_TMPFILE */
|
||||
errno==EOPNOTSUPP) /* filesystem has no support for O_TMPFILE */
|
||||
use_tmpfile = 0;
|
||||
else
|
||||
do_exit(errno, untrusted_name);
|
||||
|
Loading…
Reference in New Issue
Block a user