fix gui crash on dvdnav reporting uninitialized play positions
authorAndreas Frisch <andreas.frisch@multimedia-labs.de>
Fri, 11 Jul 2008 07:08:14 +0000 (07:08 +0000)
committerAndreas Frisch <andreas.frisch@multimedia-labs.de>
Fri, 11 Jul 2008 07:08:14 +0000 (07:08 +0000)
lib/python/Plugins/Extensions/DVDPlayer/src/servicedvd.cpp

index bbcb1f2bf7b652b17dae429db965c2ed1b2bb933..26a3ba39aa2fbf6f24b4a9e01f4e3b3790432e6e 100644 (file)
@@ -593,7 +593,10 @@ RESULT eServiceDVD::getPlayPosition(pts_t &pos)
        pos += info.pos_minutes * 60;
        pos += info.pos_seconds;
 //     eDebug("getPlayPosition %lld", pos);
        pos += info.pos_minutes * 60;
        pos += info.pos_seconds;
 //     eDebug("getPlayPosition %lld", pos);
-       pos *= 90000;
+       if ( pos > 0 && pos < 32768 )
+           pos *= 90000;
+       else
+           pos = 0;
        return 0;
 }
 
        return 0;
 }