pub enum ListenFdsError {
NoListenFds,
PidMissmatch {
listen_pid: u64,
self_pid: u64,
},
OutOfRangeListenFds,
BadListenPid(ParseIntError),
BadListenPidfdId(ParseIntError),
BadListenFds(ParseIntError),
BadListenFdNames,
}Expand description
Errors that can occur when retrieving socket-activated file descriptors.
Variants§
NoListenFds
The process was not socket-activated.
This error occurs when the LISTEN_FDS environment variable is not present,
indicating that systemd did not socket-activate this process.
PidMissmatch
The socket activation targets a different process.
This error occurs when the PID or pidfd ID in the environment variables does not match the current process, indicating the file descriptors were intended for a different process.
OutOfRangeListenFds
The LISTEN_FDS value is out of valid range.
BadListenPid(ParseIntError)
The LISTEN_PID environment variable contains an invalid PID.
BadListenPidfdId(ParseIntError)
The LISTEN_PIDFDID environment variable contains an invalid pidfd ID.
BadListenFds(ParseIntError)
The LISTEN_FDS environment variable contains an invalid number.
BadListenFdNames
The number of names in LISTEN_FDNAMES doesn’t match the number of file descriptors.