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 bbcb1f2..26a3ba3 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;
 }