[MPlayer-cvslog] r29893 - trunk/stream/stream_dvdnav.c

reimar subversion at mplayerhq.hu
Wed Nov 11 10:09:08 CET 2009


Author: reimar
Date: Wed Nov 11 10:09:08 2009
New Revision: 29893

Log:
Set the EOF flag when dvdnav reached the end of the requested title.
Otherwise it would just hang, either at the menu or trying to play the
last played frame as a still frame.

Modified:
   trunk/stream/stream_dvdnav.c

Modified: trunk/stream/stream_dvdnav.c
==============================================================================
--- trunk/stream/stream_dvdnav.c	Wed Nov 11 10:03:39 2009	(r29892)
+++ trunk/stream/stream_dvdnav.c	Wed Nov 11 10:09:08 2009	(r29893)
@@ -349,8 +349,10 @@ static int fill_buffer(stream_t *s, char
           if(dvdnav_current_title_info(priv->dvdnav, &tit, &part) == DVDNAV_STATUS_OK) {
             mp_msg(MSGT_CPLAYER,MSGL_V, "\r\nDVDNAV, NEW TITLE %d\r\n", tit);
             dvdnav_get_highlight (priv, 0);
-            if(priv->title > 0 && tit != priv->title)
+            if(priv->title > 0 && tit != priv->title) {
+              priv->state |= NAV_FLAG_EOF;
               return 0;
+            }
           }
           break;
         }
@@ -364,8 +366,10 @@ static int fill_buffer(stream_t *s, char
             priv->state |= NAV_FLAG_WAIT_READ;
           if(priv->title > 0 && dvd_last_chapter > 0) {
             int tit=0, part=0;
-            if(dvdnav_current_title_info(priv->dvdnav, &tit, &part) == DVDNAV_STATUS_OK && part > dvd_last_chapter)
+            if(dvdnav_current_title_info(priv->dvdnav, &tit, &part) == DVDNAV_STATUS_OK && part > dvd_last_chapter) {
+              priv->state |= NAV_FLAG_EOF;
               return 0;
+            }
           }
           dvdnav_get_highlight (priv, 1);
         }


More information about the MPlayer-cvslog mailing list