#1272 Use in-memory temporary files.

This commit is contained in:
Robin Mills
2017-03-05 17:42:12 +00:00
parent 013771b4c1
commit 2ebacb6b0b
15 changed files with 62 additions and 167 deletions
+1 -1
View File
@@ -159,7 +159,7 @@ namespace Exiv2 {
if (xmpPacket_.substr(0, 5) != "<?xml") {
xmpPacket_ = xmlHeader + xmpPacket_ + xmlFooter;
}
BasicIo::AutoPtr tempIo(io_->temporary()); // may throw
BasicIo::AutoPtr tempIo(new MemIo);
assert(tempIo.get() != 0);
// Write XMP packet
if ( tempIo->write(reinterpret_cast<const byte*>(xmpPacket_.data()),