diff options
| author | Tim Redfern <tim@eclectronics.org> | 2013-12-10 13:06:44 +0000 |
|---|---|---|
| committer | Tim Redfern <tim@eclectronics.org> | 2013-12-10 13:06:44 +0000 |
| commit | aef7a2c74e31ccac32a21f3fcb3c8bf26740fc89 (patch) | |
| tree | ac3c2d5f3f451d5fa52f099f46b14a2a3a637c85 /rotord/src/libavwrapper.cpp | |
| parent | 502a92835949c5da869e1748790e6e090b9c4f94 (diff) | |
| parent | 2261a9a1f146cf528e2b5142b531d14428c12f2e (diff) | |
fix up
Diffstat (limited to 'rotord/src/libavwrapper.cpp')
| -rw-r--r-- | rotord/src/libavwrapper.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/rotord/src/libavwrapper.cpp b/rotord/src/libavwrapper.cpp index d48cbc3..a6cb56d 100644 --- a/rotord/src/libavwrapper.cpp +++ b/rotord/src/libavwrapper.cpp @@ -65,9 +65,12 @@ bool libav::video_decoder::open(const std::string& filename){ } } if (makeindex) { - cerr<<"FFMS2: creating index "<<idxfile<<endl; index = FFMS_MakeIndex(filename.c_str(), 0, 0, NULL, NULL, FFMS_IEH_IGNORE, NULL, NULL, &err); - FFMS_WriteIndex(idxfile.c_str(),index,&err); + if (index) { + FFMS_WriteIndex(idxfile.c_str(),index,&err); + cerr<<"FFMS2: created index "<<idxfile<<endl; + } + cerr<<"FFMS2: "<<filename<<" cannot be indexed "<<endl; } if (index == NULL) { std::cerr<<"ffmpegsource: "<<err.Buffer<<std::endl; |
