|
|
|
@ -47,7 +47,6 @@
|
|
|
|
|
#define DEFAULT_FEC_SPAN 3
|
|
|
|
|
|
|
|
|
|
static struct {
|
|
|
|
|
int NEXT_ID;
|
|
|
|
|
int REF_COUNT;
|
|
|
|
|
int THREADCOUNT;
|
|
|
|
|
switch_memory_pool_t *pool;
|
|
|
|
@ -223,8 +222,6 @@ switch_status_t modem_init(modem_t *modem, modem_control_handler_t control_handl
|
|
|
|
|
#endif
|
|
|
|
|
logging_state_t *logging;
|
|
|
|
|
|
|
|
|
|
memset(modem, 0, sizeof(*modem));
|
|
|
|
|
|
|
|
|
|
modem->master = -1;
|
|
|
|
|
modem->slave = -1;
|
|
|
|
|
|
|
|
|
@ -298,8 +295,6 @@ switch_status_t modem_init(modem_t *modem, modem_control_handler_t control_handl
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#ifndef WIN32
|
|
|
|
|
modem->slot = globals.NEXT_ID++;
|
|
|
|
|
|
|
|
|
|
snprintf(modem->devlink, sizeof(modem->devlink), "%s/FS%d", spandsp_globals.modem_directory, modem->slot);
|
|
|
|
|
|
|
|
|
|
unlink(modem->devlink);
|
|
|
|
@ -1351,11 +1346,12 @@ static void activate_modems(void)
|
|
|
|
|
int x;
|
|
|
|
|
|
|
|
|
|
switch_mutex_lock(globals.mutex);
|
|
|
|
|
memset(globals.MODEM_POOL, 0, MAX_MODEMS);
|
|
|
|
|
memset(globals.MODEM_POOL, 0, sizeof(globals.MODEM_POOL));
|
|
|
|
|
for (x = 0; x < max; x++) {
|
|
|
|
|
|
|
|
|
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "Starting Modem SLOT %d\n", x);
|
|
|
|
|
|
|
|
|
|
globals.MODEM_POOL[x].slot = x;
|
|
|
|
|
launch_modem_thread(&globals.MODEM_POOL[x]);
|
|
|
|
|
}
|
|
|
|
|
switch_mutex_unlock(globals.mutex);
|
|
|
|
|