libbluray | branch: master | Noeri Huisman <[email protected]> | Sat Feb 20 
17:20:28 2016 +0100| [6f16e18bd09284db04a79d3bd001bb2c06c013fd] | committer: 
hpi1

Don't increment the program counter after TERMINATE_PL

_resume_from_play_pl() restores the stored pc and increments it by one. This 
function is also called via _play_stop() when a TERMINATE_PL instruction is 
executed. The program counter is than incremented once more, wrongly skipping 
an instruction.

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

 src/libbluray/hdmv/hdmv_vm.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/libbluray/hdmv/hdmv_vm.c b/src/libbluray/hdmv/hdmv_vm.c
index 7c6ba37..b52b929 100644
--- a/src/libbluray/hdmv/hdmv_vm.c
+++ b/src/libbluray/hdmv/hdmv_vm.c
@@ -1058,7 +1058,7 @@ static int _hdmv_step(HDMV_VM *p)
                         case INSN_PLAY_PL:      _play_at(p, dst,  -1,  -1); 
break;
                         case INSN_PLAY_PL_PI:   _play_at(p, dst, src,  -1); 
break;
                         case INSN_PLAY_PL_PM:   _play_at(p, dst,  -1, src); 
break;
-                        case INSN_TERMINATE_PL: _play_stop(p);              
break;
+                        case INSN_TERMINATE_PL: _play_stop(p); inc_pc = 0;  
break;
                         case INSN_LINK_PI:      _play_at(p,  -1, dst,  -1); 
break;
                         case INSN_LINK_MK:      _play_at(p,  -1,  -1, dst); 
break;
                         default:

_______________________________________________
libbluray-devel mailing list
[email protected]
https://mailman.videolan.org/listinfo/libbluray-devel

Reply via email to