From 4c830f56b2884b06a5b1ffd77ebf418f93cb59fb Mon Sep 17 00:00:00 2001 From: Robin Mills Date: Wed, 20 Feb 2013 05:28:50 +0000 Subject: [PATCH] Issue: #883. Fix for Coverity Scan Issue:982065 --- src/crwimage.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/crwimage.cpp b/src/crwimage.cpp index a641d0f8..8d7d59b2 100644 --- a/src/crwimage.cpp +++ b/src/crwimage.cpp @@ -825,7 +825,7 @@ namespace Exiv2 { if not found, create it set value */ - + AutoPtr m; CiffComponent* cc = 0; const Components::iterator b = components_.begin(); const Components::iterator e = components_.end(); @@ -842,7 +842,7 @@ namespace Exiv2 { } if (cc == 0) { // Directory doesn't exist yet, add it - AutoPtr m(new CiffDirectory(csd.crwDir_, csd.parent_)); + m = AutoPtr(new CiffDirectory(csd.crwDir_, csd.parent_)); cc = m.get(); add(m); } @@ -859,7 +859,7 @@ namespace Exiv2 { } if (cc == 0) { // Tag doesn't exist yet, add it - AutoPtr m(new CiffEntry(crwTagId, tag())); + m = AutoPtr(new CiffEntry(crwTagId, tag())); cc = m.get(); add(m); }