FreeBSD/usr.sbin/jail/state.c
/*
 * Add a dependency edge between two jails.
 */
Add a dependency edge between two jails.
Add a dependency edge between two jails .
static void
dep_add(struct cfjail *from, struct cfjail *to, unsigned flags)
{
	struct cfdepend *d;
	d = emalloc(sizeof(struct cfdepend));
	d->flags = flags;
	d->j[DEP_FROM] = from;
	d->j[DEP_TO] = to;
	STAILQ_INSERT_TAIL(&from->dep[DEP_FROM], d, tq[DEP_FROM]);
	STAILQ_INSERT_TAIL(&to->dep[DEP_TO], d, tq[DEP_TO]);
}
static void dep_add ( struct cfjail * from , struct cfjail * to , unsigned flags ) { struct cfdepend * d ; d = emalloc ( sizeof ( struct cfdepend ) ) ; d -> flags = flags ; d -> j [ DEP_FROM ] = from ; d -> j [ DEP_TO ] = to ; STAILQ_INSERT_TAIL ( & from -> dep [ DEP_FROM ] , d , tq [ DEP_FROM ] ) ; STAILQ_INSERT_TAIL ( & to -> dep [ DEP_TO ] , d , tq [ DEP_TO ] ) ; }
Add a dependency edge between two jails.
Add a dependency edge between two jails .