libmsc/sgs_vty.c: don't print SGs socket error twice

Because sgs_server_open() already does this.

Change-Id: Ifea308645c7829691dbcf53e4f59841090119006
This commit is contained in:
Vadim Yanitskiy 2019-03-21 21:27:04 +07:00
parent 4eaefc2222
commit 1d802e2635
1 changed files with 2 additions and 6 deletions

View File

@ -57,10 +57,8 @@ DEFUN(cfg_sgs_local_ip, cfg_sgs_local_ip_cmd,
osmo_stream_srv_link_set_addr(sgs->srv_link, sgs->cfg.local_addr);
rc = sgs_server_open(sgs);
if (rc < 0) {
vty_out(vty, "%% SGs socket cannot be opened: %s%s", strerror(errno), VTY_NEWLINE);
if (rc < 0)
return CMD_WARNING;
}
return CMD_SUCCESS;
}
@ -77,10 +75,8 @@ DEFUN(cfg_sgs_local_port, cfg_sgs_local_port_cmd,
osmo_stream_srv_link_set_port(sgs->srv_link, sgs->cfg.local_port);
rc = sgs_server_open(sgs);
if (rc < 0) {
vty_out(vty, "%% SGs socket cannot be opened: %s%s", strerror(errno), VTY_NEWLINE);
if (rc < 0)
return CMD_WARNING;
}
return CMD_SUCCESS;
}