version 1.1, 2012/02/21 23:32:47
|
version 1.1.1.2, 2021/03/17 00:39:23
|
Line 17
|
Line 17
|
* DEFINITIONS |
* DEFINITIONS |
*/ |
*/ |
|
|
/* Total state of a repeater */ | /* Total state of a repeater */ |
struct rep { | struct rep { |
char name[LINK_MAX_NAME]; /* Name of this repeater */ | char name[LINK_MAX_NAME]; /* Name of this repeater */ |
int id; /* Index of this link in gReps */ | int id; /* Index of this link in gReps */ |
int csock; /* Socket node control socket */ | int csock; /* Socket node control socket */ |
ng_ID_t node_id; /* ng_tee node ID */ | ng_ID_t node_id; /* ng_tee node ID */ |
Link links[2]; /* Links used by repeater */ | Link links[2]; /* Links used by repeater */ |
int refs; /* Number of references */ | int refs; /* Number of references */ |
u_char p_up; /* Up phys */ | u_char p_up; /* Up phys */ |
u_char dead; /* Dead flag */ | u_char dead; /* Dead flag */ |
}; | }; |
| |
/* |
/* |
* VARIABLES |
* VARIABLES |
*/ |
*/ |
|
|
extern const struct cmdtab RepSetCmds[]; | extern const struct cmdtab RepSetCmds[]; |
|
|
/* |
/* |
* FUNCTIONS |
* FUNCTIONS |
*/ |
*/ |
|
|
extern int RepStat(Context ctx, int ac, char *av[], void *arg); | extern int RepStat(Context ctx, int ac, const char *const av[], const void *arg); |
extern int RepCommand(Context ctx, int ac, char *av[], void *arg); | extern int RepCommand(Context ctx, int ac, const char *const av[], const void *arg); |
extern int RepCreate(Link in, const char *out); | extern int RepCreate(Link in, const char *out); |
extern void RepShutdown(Rep r); | extern void RepShutdown(Rep r); |
|
|
extern void RepIncoming(Link l); | extern void RepIncoming(Link l); |
extern int RepIsSync(Link l); /* Is pair link is synchronous */ | extern int RepIsSync(Link l); /* Is pair link is synchronous */ |
extern void RepSetAccm(Link l, u_int32_t xmit, u_int32_t recv); /* Set async accm */ | extern void RepSetAccm(Link l, u_int32_t xmit, u_int32_t recv); /* Set async accm */ |
extern void RepUp(Link l); | extern void RepUp(Link l); |
extern void RepDown(Link l); | extern void RepDown(Link l); |
extern int RepGetHook(Link l, char *path, char *hook); | extern int RepGetHook(Link l, char *path, char *hook); |
extern Rep RepFind(char *name); | extern Rep RepFind(const char *name); |
|
|
#endif |
#endif |
|
|