Empty data segment during Login Phase is rather unlikely, but it's not
a protocol error.

Sponsored by:	The FreeBSD Foundation
So, it turns out SIGCHLD is discarded by default, so we have to set up
a dummy handler to make it interrupt an ioctl(2) or select(2).

This makes those short-lived iscsid(8) zombies disappear.

Sponsored by:	The FreeBSD Foundation
Refactor.

Sponsored by:	The FreeBSD Foundation
Improve check for duplicated paths.  It shows the warning twice for
every path (once for each duplicate found), but it should do for now.

Sponsored by:	The FreeBSD Foundation
The log_whatever() routines don't accept NULL for format strings,
so mark them as __printflike instead of__printf0like.

Sponsored by:	The FreeBSD Foundation
Empty data segment during Login Phase is rather unlikely, but it's
not, by itself, a protocol error.  This fixes interoperability with
OpenBSD initiator.

Sponsored by:	The FreeBSD Foundation
Daemonize after applying configuration, not before, so that
any problems - including "daemon already running" - are visible
on the terminal and not just in logs.

Sponsored by:	The FreeBSD Foundation
Implement initiator-name and initiator-portal restrictions.

Sponsored by:	The FreeBSD Foundation
Make function ordering slightly more logical; no functional changes.

Sponsored by:	The FreeBSD Foundation
Yacc cleanup; no functional changes.

Sponsored by:	The FreeBSD Foundation
Rename a variable, no functional changes.

Sponsored by:	The FreeBSD Foundation