[Freeswitch-users] Segmentation Faults on fs_cli when trying to rescan sofia profile
Keith Laaks
keith at laaks.com
Mon Jun 29 11:04:42 UTC 2020
Hi,
I have also been experiencing this same problem.
Tested and confirmed the issue also exists in the development branch (FreeSWITCH Version 1.10.4-dev+git~20200624T182031Z~ffe0a1b629~64bit) also.
In file “sofia.c”, function “static void parse_gateways(sofia_profile_t *profile, switch_xml_t gateways_tag, const char *gwname)”,
line 4008 has:
gateway->options_user_agent = options_user_agent;
Which should instead be:
gateway->options_user_agent = switch_core_strdup(gateway->pool, options_user_agent);
——————————————————————————————————————————————————————————————————————————————————————————————————
diff --git a/src/mod/endpoints/mod_sofia/sofia.c b/src/mod/endpoints/mod_sofia/sofia.c
index 32f27462e5..da57072cca 100644
--- a/src/mod/endpoints/mod_sofia/sofia.c
+++ b/src/mod/endpoints/mod_sofia/sofia.c
@@ -4005,7 +4005,7 @@ static void parse_gateways(sofia_profile_t *profile, switch_xml_t gateways_tag,
gateway->auth_username = switch_core_strdup(gateway->pool, auth_username);
gateway->register_password = switch_core_strdup(gateway->pool, password);
gateway->distinct_to = distinct_to;
- gateway->options_user_agent = options_user_agent;
+ gateway->options_user_agent = switch_core_strdup(gateway->pool, options_user_agent);
if (switch_true(caller_id_in_from)) {
sofia_set_flag(gateway, REG_FLAG_CALLERID);
——————————————————————————————————————————————————————————————————————————————————————————————————
Not sure of the process to get this patch approved and applied to the git repo…..
Can someone in the know take care of this?
Best Regards
Keith
--------------------------------------------------------------------------------------------------------------------
On Thu, 11 Jun 2020 at 00:58, Mahmood Alkhalil
<mahmood.alkhalil at outlook.com <http://lists.freeswitch.org/mailman/listinfo/freeswitch-users>> wrote:
>
> Hi Everyone,
>
> I'm always getting segmentation fault on fs_cli whenever I'm trying to rescan sofia profile and fs_cli exists, below is an example:
>
> freeswitch at freeswitch <http://lists.freeswitch.org/mailman/listinfo/freeswitch-users>> sofia profile AtcomSipProfile rescan
> Reload XML [Success]
> +OK scan complete
>
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 debug [7]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 sip-trace [true]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 sip-capture [true]
> 2020-06-10 11:30:57.688648 [INFO] mod_enum.c:884 ENUM Reloaded
> nua_stack.c:529 nua_signal() nua((nil)): sent signal r_set_params
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 watchdog-enabled [no]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 watchdog-step-timeout [30000]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 watchdog-event-timeout [30000]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 log-auth-failures [false]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 forward-unsolicited-mwi-notify [false]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 context [atcomDialplan]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 rfc2833-pt [101]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 sip-port [5080]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 dialplan [XML]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 dtmf-duration [2000]
> 2020-06-10 11:30:57.688648 [DEBUG] sofia.c:4628 inbound-codec-prefs [OPUS,G722,PCMU,PCMA,H264,VP8]
> freeswitch at freeswitch <http://lists.freeswitch.org/mailman/listinfo/freeswitch-users>> Segmentation fault
>
> Please let me know if this is expected or if i can share more details to further investigate this.
>
> Mahmood Alkhalil.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20200629/91aaf512/attachment-0001.html>
More information about the FreeSWITCH-users
mailing list