]> git.ipfire.org Git - thirdparty/dhcpcd.git/commit
dhcpcd: Close fork_fd on hangup
authorRoy Marples <roy@marples.name>
Wed, 8 Nov 2023 11:09:52 +0000 (11:09 +0000)
committerRoy Marples <roy@marples.name>
Fri, 10 Nov 2023 11:04:22 +0000 (11:04 +0000)
commitc32c88b642b8c65eb68b505e0783fd46b57fc6fa
treefa43fc5c30c81425a027987434427000a6503f57
parent2913df520ae8ceac46bbd6bfa958cbccb0e476bf
dhcpcd: Close fork_fd on hangup

Closing it early results in zero length reads in some situations.
Logging that we forked via the launcher process also make more sense
and allows us to use log* functions.

While here, handle error condtions better by forcing a return
rather than handling an invalid state.

Fixes #260.
src/dhcpcd.c