Brandon Black 04071d64bb std.os.linux.setsid(): return raw syscall0 result
When not linking libc on 64-bit Linux and calling posix.setsid(),
we get a type error at compile time inside of posix.errno().  This
is because posix.errno()'s non-libc branch expects a usize-sized
value, which is what all the error-returning os.linux syscalls
return, and linux.setsid() instead returned a pid_t, which is only
32 bits wide.

This and the other 3 pid-related calls just below it (getpid(),
getppid(), and gettid()) are the only Linux syscall examples here
that are casting their return values to pid_t. For the other 3
this makes sense: those calls are documented to have no possible
errors and always return a valid pid_t value.

However, setsid() actually can return the error EPERM, and
therefore needs to return the raw value from syscall0 for
posix.errno() to process like normal.

Additionally, posix.setsid() needs an @intCast(rc) for the success
case as a result, like most other such cases.
2025-09-12 07:19:01 -05:00
..
2025-09-03 21:45:03 -07:00
2025-09-03 01:48:46 -07:00
2024-12-19 17:10:03 -05:00
2025-07-07 22:43:51 -07:00
2025-08-29 17:14:26 -07:00
2025-09-03 21:46:01 -07:00
2025-07-14 00:16:49 -07:00
2025-07-07 22:43:51 -07:00
2025-08-29 17:14:26 -07:00
2025-07-07 22:43:51 -07:00
2025-08-30 00:48:50 -07:00
2025-08-31 12:49:18 -07:00
2025-08-28 18:30:57 -07:00
2025-08-29 17:14:26 -07:00
2025-08-29 17:14:26 -07:00
2025-09-08 14:45:51 -05:00
2025-08-29 17:14:26 -07:00
2025-07-14 00:14:21 -07:00
2025-08-26 09:39:09 +02:00
2024-08-22 08:44:08 +02:00
2025-09-04 01:16:23 +02:00
2025-09-11 00:18:37 -07:00
2025-07-31 22:10:11 -07:00
2025-08-29 17:14:26 -07:00
2025-08-29 17:14:26 -07:00
2025-08-29 17:14:26 -07:00
2025-08-29 17:14:26 -07:00
2025-07-07 22:43:51 -07:00
2025-08-29 17:14:26 -07:00
2025-08-25 16:15:17 +02:00
2025-08-29 17:14:26 -07:00
2025-08-29 17:14:26 -07:00
2025-07-22 09:41:44 -07:00
2025-08-29 17:14:26 -07:00
2025-08-28 18:30:57 -07:00
2025-08-31 12:49:18 -07:00
2025-08-31 12:49:18 -07:00
2025-07-16 10:27:39 -07:00
2025-08-31 12:49:18 -07:00
2025-08-29 17:14:26 -07:00