[VTY] use new struct vty_app_info in libvty
This commit is contained in:
parent
4b037e4117
commit
c31f480f08
|
@ -198,10 +198,20 @@ extern int bts_model_unknown_init(void);
|
|||
extern int bts_model_bs11_init(void);
|
||||
extern int bts_model_nanobts_init(void);
|
||||
|
||||
extern int bsc_vty_go_parent(struct vty *vty);
|
||||
|
||||
static struct vty_app_info vty_info = {
|
||||
.name = "OpenBSC",
|
||||
.version = PACKAGE_VERSION,
|
||||
.go_parent_cb = bsc_vty_go_parent,
|
||||
};
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
int rc;
|
||||
|
||||
vty_info.copyright = openbsc_copyright;
|
||||
|
||||
log_init(&log_info);
|
||||
tall_bsc_ctx = talloc_named_const(NULL, 1, "openbsc");
|
||||
talloc_ctx_init();
|
||||
|
@ -219,7 +229,7 @@ int main(int argc, char **argv)
|
|||
log_set_all_filter(stderr_target, 1);
|
||||
|
||||
/* This needs to precede handle_options() */
|
||||
vty_init("OpenBSC", PACKAGE_VERSION, openbsc_copyright);
|
||||
vty_init(&vty_info);
|
||||
bsc_vty_init();
|
||||
|
||||
rc = bsc_bootstrap_network(mncc_recv, config_file);
|
||||
|
|
|
@ -185,6 +185,14 @@ static void handle_options(int argc, char **argv)
|
|||
|
||||
extern void *tall_msgb_ctx;
|
||||
|
||||
extern int bsc_vty_go_parent(struct vty *vty);
|
||||
|
||||
static struct vty_app_info vty_info = {
|
||||
.name = "Osmocom Gb Proxy",
|
||||
.version = PACKAGE_VERSION,
|
||||
.go_parent_cb = bsc_vty_go_parent,
|
||||
};
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
struct gsm_network dummy_network;
|
||||
|
@ -204,7 +212,8 @@ int main(int argc, char **argv)
|
|||
log_add_target(stderr_target);
|
||||
log_set_all_filter(stderr_target, 1);
|
||||
|
||||
vty_init("Osmocom Gb Proxy", PACKAGE_VERSION, openbsc_copyright);
|
||||
vty_info.copyright = openbsc_copyright;
|
||||
vty_init(&vty_info);
|
||||
logging_vty_add_cmds();
|
||||
gbproxy_vty_init();
|
||||
|
||||
|
|
|
@ -125,6 +125,14 @@ static void signal_handler(int signal)
|
|||
extern struct gprs_ns_inst *bssgp_nsi;
|
||||
extern void *tall_msgb_ctx;
|
||||
|
||||
extern int bsc_vty_go_parent(struct vty *vty);
|
||||
|
||||
static struct vty_app_info vty_info = {
|
||||
.name = "Osmocom SGSN",
|
||||
.version = PACKAGE_VERSION,
|
||||
.go_parent_cb = bsc_vty_go_parent,
|
||||
};
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
struct gsm_network dummy_network;
|
||||
|
@ -146,7 +154,8 @@ int main(int argc, char **argv)
|
|||
log_add_target(stderr_target);
|
||||
log_set_all_filter(stderr_target, 1);
|
||||
|
||||
vty_init("Osmocom SGSN", PACKAGE_VERSION, openbsc_copyright);
|
||||
vty_info.copyright = openbsc_copyright;
|
||||
vty_init(&vty_info);
|
||||
logging_vty_add_cmds();
|
||||
sgsn_vty_init();
|
||||
|
||||
|
|
|
@ -174,6 +174,13 @@ static int read_call_agent(struct bsc_fd *fd, unsigned int what)
|
|||
return 0;
|
||||
}
|
||||
|
||||
extern int bsc_vty_go_parent(struct vty *vty);
|
||||
|
||||
static struct vty_app_info vty_info = {
|
||||
.name = "OpenBSC MGCP",
|
||||
.version = PACKAGE_VERSION,
|
||||
.go_parent_cb = bsc_vty_go_parent,
|
||||
};
|
||||
|
||||
int main(int argc, char** argv)
|
||||
{
|
||||
|
@ -193,7 +200,8 @@ int main(int argc, char** argv)
|
|||
if (!cfg)
|
||||
return -1;
|
||||
|
||||
vty_init("OpenBSC MGCP", PACKAGE_VERSION, openbsc_copyright);
|
||||
vty_info.copyright = openbsc_copyright;
|
||||
vty_init(&vty_info);
|
||||
logging_vty_add_cmds();
|
||||
mgcp_vty_init();
|
||||
|
||||
|
|
Loading…
Reference in New Issue