FreeBSD/contrib/ntp/ntpd/ntp_io.c
/*
 * interface list enumerator - visitor pattern
 */
interface list enumerator - visitor pattern
interface list enumerator - visitor pattern
void
interface_enumerate(
	interface_receiver_t	receiver,
	void *			data
	)
{
	interface_info_t ifi;
	ifi.action = IFS_EXISTS;
	for (ifi.ep = ep_list; ifi.ep != NULL; ifi.ep = ifi.ep->elink)
		(*receiver)(data, &ifi);
}
void interface_enumerate ( interface_receiver_t receiver , void * data ) { interface_info_t ifi ; ifi . action = IFS_EXISTS ; for ( ifi . ep = ep_list ; ifi . ep != NULL ; ifi . ep = ifi . ep -> elink ) ( * receiver ) ( data , & ifi ) ; }
interface list enumerator - visitor pattern
interface list enumerator - visitor pattern