std.Io.Threaded: consider EOPNOTSUPP to be programmer error in createFileMap()

Not doing so was hiding bugs (e.g. on s390x-linux).
This commit is contained in:
Alex Rønne Petersen 2026-01-30 23:58:17 +01:00
parent c6538b70f5
commit cbe38f771c
No known key found for this signature in database

View file

@ -16796,6 +16796,7 @@ fn createFileMap(
.OVERFLOW => return error.Unseekable,
.BADF => return errnoBug(err), // Always a race condition.
.INVAL => return errnoBug(err), // Invalid parameters to mmap()
.OPNOTSUPP => return errnoBug(err), // Bad flags with MAP.SHARED_VALIDATE on Linux.
else => return posix.unexpectedErrno(err),
}
};