Алгоритми маршрутизації в мережах, Детальна інформація

Алгоритми маршрутизації в мережах
Тип документу: Курсова
Сторінок: 30
Предмет: Комп`ютерні науки
Автор:
Розмір: 26.2
Скачувань: 3080
off = 0;

if (setsockopt(rt_sock, SOL_SOCKET,SO_USELOOPBACK,

&off,sizeof(off)) < 0)

LOGERR("setsockopt(SO_USELOOPBACK,0)");

fix_select();

if (background && new_tracelevel == 0)

ftrace = 0;

if (tracename != 0) {

strncpy(inittracename, tracename, sizeof(inittracename)-1);

set_tracefile(inittracename, "%s\n", -1);

} else {

tracelevel_msg("%s\n", -1); /* turn on tracing to stdio */

}

bufinit();

/* initialize radix tree */

rtinit();

/* Pick a random part of the second for our output to minimize

* collisions.

*

* Start broadcasting after hearing from other routers, and

* at a random time so a bunch of systems do not get synchronized

* after a power failure.

*/

intvl_random(&next_bcast, EPOCH+MIN_WAITTIME, EPOCH+SUPPLY_INTERVAL);

age_timer.tv_usec = next_bcast.tv_usec;

age_timer.tv_sec = EPOCH+MIN_WAITTIME;

rdisc_timer = next_bcast;

ifinit_timer.tv_usec = next_bcast.tv_usec;

/* Collect an initial view of the world by checking the interface

* configuration and the kludge file.

The online video editor trusted by teams to make professional video in minutes