[libbluray-devel] commit: Fixed _play_hdmv() return value (1=success, 0=error) (hpi1 )

git at videolan.org git at videolan.org
Mon Nov 15 16:02:59 CET 2010


libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Mon Nov 15 16:46:01 2010 +0200| [3220df772f834f48f0f8e4a0c6f4ff9338a8cbd4] | committer: hpi1 

Fixed _play_hdmv() return value (1=success, 0=error)

> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=3220df772f834f48f0f8e4a0c6f4ff9338a8cbd4
---

 src/libbluray/bluray.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/libbluray/bluray.c b/src/libbluray/bluray.c
index 17234f6..f4b54f6 100644
--- a/src/libbluray/bluray.c
+++ b/src/libbluray/bluray.c
@@ -1586,9 +1586,13 @@ static int _play_hdmv(BLURAY *bd, unsigned id_ref)
     if (!bd->hdmv_vm) {
         bd->hdmv_vm = hdmv_vm_init(bd->device_path, bd->regs);
     }
-    bd->hdmv_suspended = 0;
 
-    return hdmv_vm_select_object(bd->hdmv_vm, id_ref);
+    if (hdmv_vm_select_object(bd->hdmv_vm, id_ref)) {
+        return 0;
+    }
+
+    bd->hdmv_suspended = 0;
+    return 1;
 }
 
 #define TITLE_FIRST_PLAY 0xffff   /* 10.4.3.2 (E) */



More information about the libbluray-devel mailing list