comparison vm.c @ 82:033f011d8152 src

Improve some debug messages. Add some comments about dvdnav_open memory leaks.
author jcdutton
date Sat, 31 Aug 2002 02:50:27 +0000
parents aa2a6e5d14cb
children 5716523464dd
comparison
equal deleted inserted replaced
81:740552dd7668 82:033f011d8152
40 #include "decoder.h" 40 #include "decoder.h"
41 #include "vmcmd.h" 41 #include "vmcmd.h"
42 #include "vm.h" 42 #include "vm.h"
43 #include "dvdnav_internal.h" 43 #include "dvdnav_internal.h"
44 44
45 /* 45
46 #define STRICT 46 #define STRICT
47 */ 47
48 48
49 /* Local prototypes */ 49 /* Local prototypes */
50 50
51 static void saveRSMinfo(vm_t *vm,int cellN, int blockN); 51 static void saveRSMinfo(vm_t *vm,int cellN, int blockN);
52 static link_t play_PGC(vm_t *vm); 52 static link_t play_PGC(vm_t *vm);
1156 1156
1157 static link_t process_command(vm_t *vm, link_t link_values) 1157 static link_t process_command(vm_t *vm, link_t link_values)
1158 { 1158 {
1159 /* FIXME $$$ Move this to a separate function? */ 1159 /* FIXME $$$ Move this to a separate function? */
1160 vm->badness_counter++; 1160 vm->badness_counter++;
1161 if (vm->badness_counter > 1) fprintf(MSG_OUT, "libdvdnav: **** process_command re-entered %d*****\n",vm->badness_counter); 1161 if (vm->badness_counter > 1) fprintf(MSG_OUT, "libdvdnav: **** WARNING: process_command re-entered %d*****\n",vm->badness_counter);
1162 while(link_values.command != PlayThis) { 1162 while(link_values.command != PlayThis) {
1163 1163
1164 #ifdef TRACE 1164 #ifdef TRACE
1165 fprintf(MSG_OUT, "libdvdnav: Before printout starts:\n");
1165 vmPrint_LINK(link_values); 1166 vmPrint_LINK(link_values);
1166 1167
1167 fprintf(MSG_OUT, "libdvdnav: Link values %i %i %i %i\n", link_values.command, 1168 fprintf(MSG_OUT, "libdvdnav: Link values %i %i %i %i\n", link_values.command,
1168 link_values.data1, link_values.data2, link_values.data3); 1169 link_values.data1, link_values.data2, link_values.data3);
1169 1170
1170 fprintf(MSG_OUT, "libdvdnav: Before:");
1171 vm_print_current_domain_state(vm); 1171 vm_print_current_domain_state(vm);
1172 fprintf(MSG_OUT, "libdvdnav: Before printout ends.\n");
1172 #endif 1173 #endif
1173 1174
1174 switch(link_values.command) { 1175 switch(link_values.command) {
1175 case LinkNoLink: 1176 case LinkNoLink:
1176 /* No Link */ 1177 /* No Link */
1498 assert(0); 1499 assert(0);
1499 break; 1500 break;
1500 } 1501 }
1501 1502
1502 #ifdef TRACE 1503 #ifdef TRACE
1503 fprintf(MSG_OUT, "libdvdnav: After:"); 1504 fprintf(MSG_OUT, "libdvdnav: After printout starts:\n");
1504 vm_print_current_domain_state(vm); 1505 vm_print_current_domain_state(vm);
1506 fprintf(MSG_OUT, "libdvdnav: After printout ends.\n");
1505 #endif 1507 #endif
1506 1508
1507 } 1509 }
1508 vm->badness_counter--; 1510 vm->badness_counter--;
1509 return link_values; 1511 return link_values;
1822 return pgcit; 1824 return pgcit;
1823 } 1825 }
1824 1826
1825 /* 1827 /*
1826 * $Log$ 1828 * $Log$
1829 * Revision 1.29 2002/08/31 02:50:27 jcdutton
1830 * Improve some debug messages.
1831 * Add some comments about dvdnav_open memory leaks.
1832 *
1827 * Revision 1.28 2002/08/29 05:33:54 jcdutton 1833 * Revision 1.28 2002/08/29 05:33:54 jcdutton
1828 * Slight changes to help debugging. 1834 * Slight changes to help debugging.
1829 * 1835 *
1830 * Revision 1.27 2002/08/29 04:01:43 jcdutton 1836 * Revision 1.27 2002/08/29 04:01:43 jcdutton
1831 * Remove an assert() so that user initiated jumps to particlar menus does not seg fault if 1837 * Remove an assert() so that user initiated jumps to particlar menus does not seg fault if