aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/skpdiff/SkDiffContext.cpp
diff options
context:
space:
mode:
authorGravatar djsollen@google.com <djsollen@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2014-02-11 16:22:58 +0000
committerGravatar djsollen@google.com <djsollen@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2014-02-11 16:22:58 +0000
commit60bce6cfcc15f48875b6898e0ac3024ff6047068 (patch)
tree00e7f9dfb3e053893f8bf8dd7dc01358379b9973 /tools/skpdiff/SkDiffContext.cpp
parent09f0ba7eb3c1933c7be878a043de5c287edd00ab (diff)
Return -1 in error condition instead of removing diff result.
BUG=skia:2160 R=epoger@google.com Review URL: https://codereview.chromium.org/145123013 git-svn-id: http://skia.googlecode.com/svn/trunk@13407 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'tools/skpdiff/SkDiffContext.cpp')
-rw-r--r--tools/skpdiff/SkDiffContext.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/skpdiff/SkDiffContext.cpp b/tools/skpdiff/SkDiffContext.cpp
index 2bd1694a08..a1cc665dc2 100644
--- a/tools/skpdiff/SkDiffContext.cpp
+++ b/tools/skpdiff/SkDiffContext.cpp
@@ -107,8 +107,8 @@ void SkDiffContext::addDiff(const char* baselinePath, const char* testPath) {
diffData.fDiffName = differ->getName();
if (!differ->diff(&baselineBitmap, &testBitmap, alphaMaskPending, &diffData.fResult)) {
- // if the diff failed the remove its entry from the list
- newRecord->fDiffs.pop_back();
+ // if the diff failed record -1 as the result
+ diffData.fResult = -1;
continue;
}