Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
8d263243
Commit
8d263243
authored
Mar 18, 2006
by
Clément Stenac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't use %f in VLM, except for display (Closes:#588)
parent
019ee285
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
6 deletions
+10
-6
src/misc/vlm.c
src/misc/vlm.c
+10
-6
No files found.
src/misc/vlm.c
View file @
8d263243
...
...
@@ -1234,11 +1234,15 @@ int vlm_MediaControl( vlm_t *vlm, vlm_media_t *media, const char *psz_id,
vlc_value_t
val
;
float
f_percentage
;
if
(
psz_args
&&
sscanf
(
psz_args
,
"%f"
,
&
f_percentage
)
==
1
)
if
(
psz_args
)
{
val
.
f_float
=
f_percentage
/
100
.
0
;
var_Set
(
p_instance
->
p_input
,
"position"
,
val
);
return
VLC_SUCCESS
;
f_percentage
=
i18n_atof
(
psz_args
);
if
(
f_percentage
>=
0
.
0
&&
f_percentage
<=
100
.
0
)
{
val
.
f_float
=
f_percentage
/
100
.
0
;
var_Set
(
p_instance
->
p_input
,
"position"
,
val
);
return
VLC_SUCCESS
;
}
}
}
else
if
(
!
strcmp
(
psz_command
,
"stop"
)
)
...
...
@@ -2312,8 +2316,8 @@ int vlm_MediaVodControl( void *p_private, vod_media_t *p_vod_media,
{
double
f_pos
=
(
double
)
va_arg
(
args
,
double
);
char
psz_pos
[
50
];
sprintf
(
psz_pos
,
"%f"
,
f_pos
);
lldiv_t
div
=
lldiv
(
f_pos
*
10000000
,
10000000
);
sprintf
(
psz_pos
,
I64Fd
".%07u"
,
div
.
quot
,
(
unsigned
int
)
div
.
rem
);
i_ret
=
vlm_MediaControl
(
vlm
,
vlm
->
media
[
i
],
psz_id
,
"seek"
,
psz_pos
);
break
;
}
...
...
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