# HG changeset patch # User mroi # Date 1096571796 0 # Node ID aee8af592d66093e1ae7aa27871dddb0c8c965a8 # Parent 1c8dc80922d3355f81a5c03378d10f885938c828 fix a long-standing problem: sometimes, hitting Escape in the movie and then again in the menu does not resume the movie, but throws "Expected NAV packet, but none found." at you; reason: link_values.data1, which we use to transport the block number for the resume is 16bit, but blockN is 32bit and can actually use more than 16bit sometimes; solution: use link_values.data2 for the upper 16bit (I did not want to change the declaration of link_t, because it seems closer to the DVD standard to have 16bit wide entries there, actually we are abusing the link_values for the resume block number anyway.) diff -r 1c8dc80922d3 -r aee8af592d66 vm/vm.c --- a/vm/vm.c Mon Sep 27 12:24:01 2004 +0000 +++ b/vm/vm.c Thu Sep 30 19:16:36 2004 +0000 @@ -1343,10 +1343,11 @@ (vm->state).pgN = 1; link_values = play_PG(vm); } else { - /* (vm->state).pgN = ?? this gets the righ value in set_PGN() below */ + /* (vm->state).pgN = ?? this gets the right value in set_PGN() below */ (vm->state).cellN = (vm->state).rsm_cellN; link_values.command = PlayThis; - link_values.data1 = (vm->state).rsm_blockN; + link_values.data1 = (vm->state).rsm_blockN & 0xffff; + link_values.data2 = (vm->state).rsm_blockN >> 16; if(!set_PGN(vm)) { /* Were at the end of the PGC, should not happen for a RSM */ assert(0); @@ -1549,7 +1550,7 @@ #endif } - (vm->state).blockN = link_values.data1; + (vm->state).blockN = link_values.data1 | (link_values.data2 << 16); return 1; }