Merge pull request #69 in FS/freeswitch from ~HRISTO/freeswitch:conference-flags to master
* commit '3695bdd9e4e0d925ab7296d2f4ce120bf656f623': set conference flags from a dial plan variable or via +flags{ }
This commit is contained in:
commit
fbe81ff886
|
@ -9081,6 +9081,7 @@ SWITCH_STANDARD_APP(conference_function)
|
|||
char *profile_name = NULL;
|
||||
switch_xml_t cxml = NULL, cfg = NULL, profiles = NULL;
|
||||
const char *flags_str, *v_flags_str;
|
||||
const char *cflags_str, *v_cflags_str;
|
||||
member_flag_t mflags = 0;
|
||||
switch_core_session_message_t msg = { 0 };
|
||||
uint8_t rl = 0, isbr = 0;
|
||||
|
@ -9144,6 +9145,16 @@ SWITCH_STANDARD_APP(conference_function)
|
|||
}
|
||||
}
|
||||
|
||||
cflags_str = flags_str;
|
||||
|
||||
if ((v_cflags_str = switch_channel_get_variable(channel, "conference_flags"))) {
|
||||
if (zstr(cflags_str)) {
|
||||
cflags_str = v_cflags_str;
|
||||
} else {
|
||||
cflags_str = switch_core_session_sprintf(session, "%s|%s", cflags_str, v_cflags_str);
|
||||
}
|
||||
}
|
||||
|
||||
/* is this a bridging conference ? */
|
||||
if (!strncasecmp(mydata, bridge_prefix, strlen(bridge_prefix))) {
|
||||
isbr = 1;
|
||||
|
@ -9234,6 +9245,8 @@ SWITCH_STANDARD_APP(conference_function)
|
|||
goto done;
|
||||
}
|
||||
|
||||
set_cflags(cflags_str, &conference->flags);
|
||||
|
||||
if (locked) {
|
||||
switch_mutex_unlock(globals.setup_mutex);
|
||||
locked = 0;
|
||||
|
@ -9316,6 +9329,8 @@ SWITCH_STANDARD_APP(conference_function)
|
|||
goto done;
|
||||
}
|
||||
|
||||
set_cflags(cflags_str, &conference->flags);
|
||||
|
||||
if (locked) {
|
||||
switch_mutex_unlock(globals.setup_mutex);
|
||||
locked = 0;
|
||||
|
|
Loading…
Reference in New Issue