diff options
author | Jochen Dolze <vdr@dolze.de> | 2010-03-18 22:16:11 +0100 |
---|---|---|
committer | Jochen Dolze <vdr@dolze.de> | 2010-03-18 22:16:11 +0100 |
commit | 851f798a581fa64317b69cace972782d73e6c379 (patch) | |
tree | d95418dc08d0350a39b91d994ea3f192574b56e8 /markad-standalone.cpp | |
parent | 574b563d9701ca6710bf637fd34fb135474b5194 (diff) | |
download | vdr-plugin-markad-851f798a581fa64317b69cace972782d73e6c379.tar.gz vdr-plugin-markad-851f798a581fa64317b69cace972782d73e6c379.tar.bz2 |
Fixed CheckIndex
Diffstat (limited to 'markad-standalone.cpp')
-rw-r--r-- | markad-standalone.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/markad-standalone.cpp b/markad-standalone.cpp index 2521986..823e0ce 100644 --- a/markad-standalone.cpp +++ b/markad-standalone.cpp @@ -112,7 +112,7 @@ void cMarkAdStandalone::SaveFrame(int frame) fclose(pFile); } -void cMarkAdStandalone::CheckIndex() +void cMarkAdStandalone::CheckIndex(bool NoLastFrameCheck) { // Here we check the indexfile // if we have an index we check if the @@ -132,7 +132,10 @@ void cMarkAdStandalone::CheckIndex() if (stat(indexFile,&statbuf)==-1) return; int maxframes=statbuf.st_size/8; - if (lastmaxframes==maxframes) return; // no new frames still last call! + if (NoLastFrameCheck) + { + if (lastmaxframes==maxframes) return; // no new frames still last call! + } if (maxframes<(framecnt+200)) { @@ -181,7 +184,7 @@ bool cMarkAdStandalone::ProcessFile(const char *Directory, int Number) free(fbuf); if (f==-1) return false; - CheckIndex(); + CheckIndex(true); if (abort) return false; int dataread; @@ -331,7 +334,7 @@ bool cMarkAdStandalone::ProcessFile(const char *Directory, int Number) } } } - CheckIndex(); + CheckIndex(false); if (abort) { if (f!=-1) close(f); |