aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/libbsc/bsc_init.c
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2017-05-29 13:42:19 +0200
committerHarald Welte <laforge@gnumonks.org>2017-05-29 13:45:04 +0200
commit8254cf75bf818e715201c670c7fb81b9a23dec0b (patch)
treeb60e07f8741f38631d0dc0b5e8014c7d1fdad969 /openbsc/src/libbsc/bsc_init.c
parent3f86c523eea75e3da7f0495c7e43b944356d2321 (diff)
libbsc: Create pcu-socket only as specified in config file
Since commit b4999b60d48bcbb5aa575973d068e07ab672e095 we created PCU sockets at hard-coded paths in the filesystem by default for all BTSs. This is inflexible and prevents the use of multiple BSC instances on a single filesystem, or the placement of the sockets in a more secure location than /tmp. The new approach with this patch is that * no PCU sockets are created by default * only for those BTSs where a 'pcu-socket' is configured via VTY, the socket will actually be created Change-Id: Ie9079470584777dcc31f85f9bf0808f479156ccb Closes: OS#2293
Diffstat (limited to 'openbsc/src/libbsc/bsc_init.c')
-rw-r--r--openbsc/src/libbsc/bsc_init.c14
1 files changed, 0 insertions, 14 deletions
diff --git a/openbsc/src/libbsc/bsc_init.c b/openbsc/src/libbsc/bsc_init.c
index 520b2e24e..caec8005d 100644
--- a/openbsc/src/libbsc/bsc_init.c
+++ b/openbsc/src/libbsc/bsc_init.c
@@ -507,8 +507,6 @@ int bsc_network_configure(const char *config_file)
{
struct gsm_bts *bts;
int rc;
- char pcu_sock_path[PATH_MAX];
- char pcu_sock_path_ending[PATH_MAX];
rc = vty_read_config_file(config_file, NULL);
if (rc < 0) {
@@ -536,18 +534,6 @@ int bsc_network_configure(const char *config_file)
LOGP(DNM, LOGL_FATAL, "Error enabling E1 input driver\n");
return rc;
}
-
- strcpy(pcu_sock_path, PCU_SOCK_DEFAULT);
- sprintf(pcu_sock_path_ending,"_%i", bts->nr);
- if (bts->nr > 0)
- strcat(pcu_sock_path, pcu_sock_path_ending);
- rc = pcu_sock_init(pcu_sock_path, bts);
-
- if (rc < 0) {
- LOGP(DNM, LOGL_FATAL,
- "PCU L1 socket failed for bts %i\n", bts->nr);
- return rc;
- }
}
return 0;