comparison mplayer.c @ 31148:6957d78df897

Use MP_NOPTS_VALUE as "default" pts for delayed frames instead of some insanely large value. Avoids hang if a decoder handles the data/size == 0 condition incorrectly.
author reimar
date Sun, 23 May 2010 23:22:25 +0000
parents ba91602b82c5
children 203789464176
comparison
equal deleted inserted replaced
31147:97660f5d9aef 31148:6957d78df897
1799 current_module = "video_read_frame"; 1799 current_module = "video_read_frame";
1800 in_size = ds_get_packet_pts(d_video, &start, &pts); 1800 in_size = ds_get_packet_pts(d_video, &start, &pts);
1801 if (in_size < 0) { 1801 if (in_size < 0) {
1802 // try to extract last frames in case of decoder lag 1802 // try to extract last frames in case of decoder lag
1803 in_size = 0; 1803 in_size = 0;
1804 pts = 1e300; 1804 pts = MP_NOPTS_VALUE;
1805 hit_eof = 1; 1805 hit_eof = 1;
1806 } 1806 }
1807 if (in_size > max_framesize) 1807 if (in_size > max_framesize)
1808 max_framesize = in_size; 1808 max_framesize = in_size;
1809 current_module = "decode video"; 1809 current_module = "decode video";