From: Seven Du Date: Fri, 19 Apr 2019 17:58:40 +0000 (+0800) Subject: FS-11721 don't automatically send unicode linefeed on MSRP X-Git-Tag: v1.10.0~124 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0bf7bb063566287e6bfa28733c93d35bd564025a;p=thirdparty%2Ffreeswitch.git FS-11721 don't automatically send unicode linefeed on MSRP --- diff --git a/src/switch_core_media.c b/src/switch_core_media.c index 3d60aa5756..bb974db6da 100644 --- a/src/switch_core_media.c +++ b/src/switch_core_media.c @@ -7236,7 +7236,9 @@ static void *SWITCH_THREAD_FUNC text_helper_thread(switch_thread_t *thread, void switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "%s Text thread started.\n", switch_channel_get_name(session->channel)); - switch_core_session_write_text_frame(session, &cr_frame, 0, 0); + if (!switch_channel_test_flag(channel, CF_MSRP)) { + switch_core_session_write_text_frame(session, &cr_frame, 0, 0); + } while (switch_channel_up_nosig(channel)) { @@ -11268,6 +11270,7 @@ SWITCH_DECLARE(void) switch_core_media_gen_local_sdp(switch_core_session_t *sess switch_channel_set_flag(session->channel, CF_HAS_TEXT); switch_channel_set_flag(session->channel, CF_TEXT_POSSIBLE); + switch_channel_set_flag(session->channel, CF_TEXT_LINE_BASED); switch_channel_set_flag(session->channel, CF_MSRP); if (want_msrps) {