mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-27 23:08:31 +00:00
Improve system call wrappers
This change improves copy_file_range(), sendfile(), splice(), openpty(), closefrom(), close_range(), fadvise() and posix_fadvise() in addition to writing tests that confirm things like errno and seeking behavior across platforms. We now less aggressively polyfill behavior with some of these functions when the platform support isn't available. Please see: https://justine.lol/cosmopolitan/functions.html
This commit is contained in:
parent
224c12f54d
commit
c7a8cd21e9
89 changed files with 1151 additions and 414 deletions
|
@ -27,8 +27,8 @@
|
|||
* @return 0 on success, or errno on error
|
||||
* @raise ENOSYS if not Linux or Windows
|
||||
*/
|
||||
int pthread_setaffinity_np(pthread_t thread, size_t bitsetsize,
|
||||
const cpu_set_t *bitset) {
|
||||
errno_t pthread_setaffinity_np(pthread_t thread, size_t bitsetsize,
|
||||
const cpu_set_t *bitset) {
|
||||
int rc, e = errno;
|
||||
struct PosixThread *pt = (struct PosixThread *)thread;
|
||||
if (!sched_setaffinity(pt->tid, bitsetsize, bitset)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue