#1244 Fix crwimage.cpp to read into memory (to make CRW work with RemoteIo).

v0.27.3
Robin Mills 9 years ago
parent 03ca00fc1e
commit 022e18dc6f

@ -131,6 +131,16 @@ namespace Exiv2 {
throw Error(33);
}
clearMetadata();
// read all metadata into memory
// we should put this into clearMetadata(), however it breaks the test suite!
try {
std::ofstream devnull;
printStructure(devnull,kpsRecursive,0);
} catch (Exiv2::Error& e) {
DataBuf file(io().size());
io_->read(file.pData_,file.size_);
}
CrwParser::decode(this, io_->mmap(), io_->size());
} // CrwImage::readMetadata

Loading…
Cancel
Save