Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linphone-desktop
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
linphone-desktop
Commits
28158775
Commit
28158775
authored
Aug 16, 2017
by
Ronan Abhamon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(Cli): add a `static_cast` on header length (executeUri)
parent
5cb47b0e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
Cli.cpp
src/app/cli/Cli.cpp
+4
-5
No files found.
src/app/cli/Cli.cpp
View file @
28158775
...
...
@@ -52,14 +52,13 @@ static void cliJoinConference (QHash<QString, QString> &args) {
CoreManager
::
getInstance
()
->
getCallsListModel
()
->
launchAudioCall
(
sipAddress
,
args
);
}
static
void
cliJoinConferenceAs
(
QHash
<
QString
,
QString
>
&
args
)
{
const
QString
toSipAddress
=
args
.
take
(
"sip-address"
);
const
QString
fromSipAddress
=
args
.
take
(
"guest-sip-address"
);
shared_ptr
<
linphone
::
Core
>
core
=
CoreManager
::
getInstance
()
->
getCore
();
shared_ptr
<
linphone
::
Address
>
currentSipAddress
=
core
->
getDefaultProxyConfig
()
->
getIdentityAddress
()
->
clone
();
currentSipAddress
->
clean
();
if
(
fromSipAddress
!=
::
Utils
::
coreStringToAppString
(
currentSipAddress
->
asStringUriOnly
()))
{
if
(
fromSipAddress
!=
::
Utils
::
coreStringToAppString
(
currentSipAddress
->
asStringUriOnly
()))
{
qWarning
()
<<
QStringLiteral
(
"guest sip address `%1` is not one of yours."
)
.
arg
(
fromSipAddress
);
return
;
...
...
@@ -167,10 +166,10 @@ void Cli::Command::execute (QHash<QString, QString> &args) const {
void
Cli
::
Command
::
executeUri
(
const
shared_ptr
<
linphone
::
Address
>
&
address
)
const
{
QHash
<
QString
,
QString
>
args
;
//TODO: check if there is too much headers.
//
TODO: check if there is too much headers.
for
(
const
auto
&
argName
:
mArgsScheme
.
keys
())
{
const
string
header
=
address
->
getHeader
(
::
Utils
::
appStringToCoreString
(
argName
));
args
[
argName
]
=
QByteArray
::
fromBase64
(
QByteArray
(
header
.
c_str
(),
header
.
length
(
)));
args
[
argName
]
=
QByteArray
::
fromBase64
(
QByteArray
(
header
.
c_str
(),
static_cast
<
int
>
(
header
.
length
()
)));
}
address
->
clean
();
args
[
"sip-address"
]
=
::
Utils
::
coreStringToAppString
(
address
->
asStringUriOnly
());
...
...
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