Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
liblinphone
Commits
489c03a8
Commit
489c03a8
authored
Jul 11, 2016
by
Sylvain Berfini
🐮
Browse files
Fix issue with trim function
parent
cad62d59
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
coreapi/sal.c
coreapi/sal.c
+6
-5
No files found.
coreapi/sal.c
View file @
489c03a8
...
...
@@ -853,12 +853,13 @@ const char* sal_privacy_to_string(SalPrivacy privacy) {
}
}
static
void
remove_trailing_spaces
(
char
*
line
){
size_t
i
;
for
(
i
=
strlen
(
line
)
-
1
;
i
>=
0
;
--
i
){
if
(
isspace
(
line
[
i
]))
line
[
i
]
=
'\0'
;
e
lse
break
;
static
void
remove_trailing_spaces
(
char
*
line
)
{
size_t
size
=
size
=
strlen
(
line
)
;
char
*
end
=
line
+
size
-
1
;
while
(
end
>=
line
&&
isspace
(
*
end
))
{
e
nd
--
;
}
*
(
end
+
1
)
=
'\0'
;
}
static
int
line_get_value
(
const
char
*
input
,
const
char
*
key
,
char
*
value
,
size_t
value_size
,
size_t
*
read
){
...
...
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