mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Fixed replaying in case there is no index file
This commit is contained in:
parent
780cd3d52f
commit
ab4e3c7ef8
1
HISTORY
1
HISTORY
@ -587,3 +587,4 @@ Video Disk Recorder Revision History
|
|||||||
may be necessary if your multiswitch gets irritated by the default DiSEqC
|
may be necessary if your multiswitch gets irritated by the default DiSEqC
|
||||||
codes '0' (thanks to Markus Lang).
|
codes '0' (thanks to Markus Lang).
|
||||||
- Avoiding audio/video distortions in 'Transfer Mode'.
|
- Avoiding audio/video distortions in 'Transfer Mode'.
|
||||||
|
- Fixed replaying in case there is no index file.
|
||||||
|
6
dvbapi.c
6
dvbapi.c
@ -4,7 +4,7 @@
|
|||||||
* See the main source file 'vdr.c' for copyright information and
|
* See the main source file 'vdr.c' for copyright information and
|
||||||
* how to reach the author.
|
* how to reach the author.
|
||||||
*
|
*
|
||||||
* $Id: dvbapi.c 1.91 2001/07/28 11:23:59 kls Exp $
|
* $Id: dvbapi.c 1.92 2001/07/28 11:38:21 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "dvbapi.h"
|
#include "dvbapi.h"
|
||||||
@ -735,7 +735,7 @@ void cReplayBuffer::Input(void)
|
|||||||
r = ReadFrame(replayFile, b, Length, sizeof(b));
|
r = ReadFrame(replayFile, b, Length, sizeof(b));
|
||||||
StripAudioPackets(b, r);
|
StripAudioPackets(b, r);
|
||||||
}
|
}
|
||||||
else {
|
else if (index) {
|
||||||
lastIndex = -1;
|
lastIndex = -1;
|
||||||
playIndex = (playIndex >= 0) ? playIndex + 1 : index->Get(fileName.Number(), fileOffset);
|
playIndex = (playIndex >= 0) ? playIndex + 1 : index->Get(fileName.Number(), fileOffset);
|
||||||
uchar FileNumber;
|
uchar FileNumber;
|
||||||
@ -745,6 +745,8 @@ void cReplayBuffer::Input(void)
|
|||||||
r = ReadFrame(replayFile, b, Length, sizeof(b));
|
r = ReadFrame(replayFile, b, Length, sizeof(b));
|
||||||
StripAudioPackets(b, r, audioTrack);
|
StripAudioPackets(b, r, audioTrack);
|
||||||
}
|
}
|
||||||
|
else // allows replay even if the index file is missing
|
||||||
|
r = read(replayFile, b, sizeof(b));
|
||||||
if (r > 0) {
|
if (r > 0) {
|
||||||
uchar *p = b;
|
uchar *p = b;
|
||||||
while (r > 0 && Busy() && !blockInput) {
|
while (r > 0 && Busy() && !blockInput) {
|
||||||
|
Loading…
Reference in New Issue
Block a user