[vlc-devel] commit: mod: Fix an other bad cast from function call. (Pierre d'Herbemont )
git version control
git at videolan.org
Thu Aug 20 14:28:33 CEST 2009
vlc | branch: master | Pierre d'Herbemont <pdherbemont at free.fr> | Thu Aug 20 12:24:50 2009 +0200| [c3cf43d7760cd2224fcfb74137f5fb908a8ac584] | committer: Pierre d'Herbemont
mod: Fix an other bad cast from function call.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c3cf43d7760cd2224fcfb74137f5fb908a8ac584
---
modules/demux/mod.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/modules/demux/mod.c b/modules/demux/mod.c
index 7569469..f3f162c 100644
--- a/modules/demux/mod.c
+++ b/modules/demux/mod.c
@@ -318,7 +318,9 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
pf = (double*) va_arg( args, double* );
if( p_sys->i_length > 0 )
{
- *pf = (double)date_Get( &p_sys->pts ) / (double)p_sys->i_length;
+ double current = date_Get( &p_sys->pts );
+ double length = p_sys->i_length;
+ *pf = current / length;
return VLC_SUCCESS;
}
return VLC_EGENERIC;
More information about the vlc-devel
mailing list