Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
BC
public
liblinphone
Commits
8720f2ac
Commit
8720f2ac
authored
Dec 19, 2017
by
Sylvain Berfini
🎩
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed issue with dialplan
parent
e5b624e8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
4 deletions
+9
-4
coreapi/proxy.c
coreapi/proxy.c
+9
-4
No files found.
coreapi/proxy.c
View file @
8720f2ac
...
...
@@ -669,16 +669,21 @@ char* linphone_proxy_config_normalize_phone_number(LinphoneProxyConfig *proxy, c
ms_message
(
"Unknown ccc for e164 like number [%s]"
,
flatten
);
goto
end
;
}
else
{
dialplan
=
DialPlan
::
findByCcc
(
tmpproxy
->
dial_prefix
);
//copy dial plan;
if
(
tmpproxy
->
dial_prefix
)
{
dialplan
=
DialPlan
::
findByCcc
(
tmpproxy
->
dial_prefix
);
//copy dial plan;
}
else
{
dialplan
=
DialPlan
::
MostCommon
;
}
if
(
tmpproxy
->
dial_prefix
){
if
(
strcmp
(
tmpproxy
->
dial_prefix
,
dialplan
.
getCountryCallingCode
().
c_str
())
!=
0
){
//probably generic dialplan, preserving proxy dial prefix
dialplan
.
setCountryCallingCode
(
tmpproxy
->
dial_prefix
);
}
/*it does not make sens to try replace icp with + if we are not sure from the country we are (I.E tmpproxy->dial_prefix==NULL)*/
if
(
strstr
(
flatten
,
dialplan
.
getInternationalCallPrefix
().
c_str
())
==
flatten
)
{
char
*
e164
=
replace_icp_with_plus
(
flatten
,
dialplan
.
getI
soCountryCode
().
c_str
());
result
=
linphone_proxy_config_normalize_phone_number
(
tmpproxy
,
e164
);
if
(
strstr
(
flatten
,
dialplan
.
getInternationalCallPrefix
().
c_str
())
==
flatten
)
{
char
*
e164
=
replace_icp_with_plus
(
flatten
,
dialplan
.
getI
nternationalCallPrefix
().
c_str
());
result
=
linphone_proxy_config_normalize_phone_number
(
tmpproxy
,
e164
);
ms_free
(
e164
);
goto
end
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment