diff options
author | vandebo@chromium.org <vandebo@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2011-02-01 01:04:00 +0000 |
---|---|---|
committer | vandebo@chromium.org <vandebo@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2011-02-01 01:04:00 +0000 |
commit | e527c874f27b655d90322141c06f7ec956dc5426 (patch) | |
tree | 9a273ebf8e6ac127ce620df7c618c9776d7f4d8a /pdf | |
parent | 9e4f15cf5552d239f74a73ad139a492119464f56 (diff) | |
download | src-e527c874f27b655d90322141c06f7ec956dc5426.tar.gz |
[PDF] Fix bugs preventing gm from running with PDF support.
Fix copy-paste ref counting bug.
Change NOT_IMPLEMENTED macro to only assert in debug mode.
Review URL: http://codereview.appspot.com/4080048
git-svn-id: http://skia.googlecode.com/svn/trunk/src@748 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'pdf')
-rw-r--r-- | pdf/SkPDFDevice.cpp | 2 | ||||
-rw-r--r-- | pdf/SkPDFImage.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/pdf/SkPDFDevice.cpp b/pdf/SkPDFDevice.cpp index d3a15a8b..3ca74098 100644 --- a/pdf/SkPDFDevice.cpp +++ b/pdf/SkPDFDevice.cpp @@ -36,7 +36,7 @@ do { \ if (condition) { \ fprintf(stderr, "NOT_IMPLEMENTED: " #condition "\n"); \ - SkASSERT(!assert); \ + SkDEBUGCODE(SkASSERT(!assert);) \ } \ } while(0) diff --git a/pdf/SkPDFImage.cpp b/pdf/SkPDFImage.cpp index 6c35f5a6..f3f75925 100644 --- a/pdf/SkPDFImage.cpp +++ b/pdf/SkPDFImage.cpp @@ -228,8 +228,8 @@ SkPDFArray* makeIndexedColorSpace(SkColorTable* table) { rgbName->unref(); // SkRefPtr and new both took a reference. result->append(rgbName.get()); - rgbName->unref(); // SkRefPtr and new both took a reference. SkRefPtr<SkPDFInt> countValue = new SkPDFInt(table->count() - 1); + countValue->unref(); // SkRefPtr and new both took a reference. result->append(countValue.get()); // Potentially, this could be represented in fewer bytes with a stream. |