[vlc-commits] core: mtime: assert divider_num is not 0
Marvin Scholz
git at videolan.org
Mon Jul 29 12:01:43 CEST 2019
vlc | branch: master | Marvin Scholz <epirat07 at gmail.com> | Sun Jul 28 13:11:44 2019 +0200| [c7e938f35db51827fad7145beb37fcf662f48c52] | committer: Marvin Scholz
core: mtime: assert divider_num is not 0
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c7e938f35db51827fad7145beb37fcf662f48c52
---
src/misc/mtime.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/misc/mtime.c b/src/misc/mtime.c
index eef1950b59..fb1532554a 100644
--- a/src/misc/mtime.c
+++ b/src/misc/mtime.c
@@ -76,6 +76,7 @@ void date_Init( date_t *p_date, uint32_t i_divider_n, uint32_t i_divider_d )
void date_Change( date_t *p_date, uint32_t i_divider_n, uint32_t i_divider_d )
{
+ assert( p_date->i_divider_num != 0 );
/* change time scale of remainder */
p_date->i_remainder = p_date->i_remainder * i_divider_n / p_date->i_divider_num;
p_date->i_divider_num = i_divider_n;
More information about the vlc-commits
mailing list