changeset 10930:624f11cc5034

Fix for imprecise floating point calculations.
author mosu
date Mon, 22 Sep 2003 13:53:29 +0000
parents fc2cfb994784
children 7c7a103fa157
files libmpdemux/demux_mkv.cpp
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libmpdemux/demux_mkv.cpp	Mon Sep 22 13:44:36 2003 +0000
+++ b/libmpdemux/demux_mkv.cpp	Mon Sep 22 13:53:29 2003 +0000
@@ -2190,6 +2190,8 @@
 
               current_pts = (float)(kblock->GlobalTimecode() / 1000000.0 -
                                     mkv_d->first_tc) / 1000.0;
+              if (current_pts < 0.0)
+                current_pts = 0.0;
 
               if (ds == d->audio) {
                 if (mkv_d->a_skip_to_keyframe &&