From 71cbc5c6360df4421cca3565e98f57c2340c98a0 Mon Sep 17 00:00:00 2001 From: Evangelos Ribeiro Tzaras Date: Thu, 1 Apr 2021 18:24:09 +0200 Subject: [PATCH] sip: provider: Fall back to reasonable values for local-port property --- plugins/sip/calls-sip-provider.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/plugins/sip/calls-sip-provider.c b/plugins/sip/calls-sip-provider.c index 182a659..c945567 100644 --- a/plugins/sip/calls-sip-provider.c +++ b/plugins/sip/calls-sip-provider.c @@ -159,6 +159,12 @@ calls_sip_provider_load_accounts (CallsSipProvider *self) else port = 5060; } + if (local_port == 0) { + if (g_strcmp0 (protocol, "TLS") == 0) + local_port = 5061; + else + local_port = 5060; + } g_debug ("Adding origin for SIP account %s", groups[i]);