Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(550)

Unified Diff: src/codec/SkCodec_libpng.cpp

Issue 1032093004: Use a wrapper for SkDebugf in SkCodec. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/codec/SkCodec_libico.cpp ('k') | src/codec/SkMasks.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/codec/SkCodec_libpng.cpp
diff --git a/src/codec/SkCodec_libpng.cpp b/src/codec/SkCodec_libpng.cpp
index 8c0b624b8d810eee8bf8ecf5f0ac8cfe78120c87..8f2bdd35a00da5760e8284e3c4bf36d89e304e07 100644
--- a/src/codec/SkCodec_libpng.cpp
+++ b/src/codec/SkCodec_libpng.cpp
@@ -46,7 +46,7 @@
///////////////////////////////////////////////////////////////////////////////
static void sk_error_fn(png_structp png_ptr, png_const_charp msg) {
- SkDebugf("------ png error %s\n", msg);
+ SkCodecPrintf("------ png error %s\n", msg);
longjmp(png_jmpbuf(png_ptr), 1);
}
@@ -369,7 +369,7 @@ SkCodec::Result SkPngCodec::initializeSwizzler(const SkImageInfo& requestedInfo,
// FIXME: Could we use the return value of setjmp to specify the type of
// error?
if (setjmp(png_jmpbuf(fPng_ptr))) {
- SkDebugf("setjmp long jump!\n");
+ SkCodecPrintf("setjmp long jump!\n");
return kInvalidInput;
}
@@ -436,7 +436,7 @@ SkCodec::Result SkPngCodec::onGetPixels(const SkImageInfo& requestedInfo, void*
// FIXME: Could we use the return value of setjmp to specify the type of
// error?
if (setjmp(png_jmpbuf(fPng_ptr))) {
- SkDebugf("setjmp long jump!\n");
+ SkCodecPrintf("setjmp long jump!\n");
return kInvalidInput;
}
@@ -505,7 +505,7 @@ public:
SkImageGenerator::Result onGetScanlines(void* dst, int count, size_t rowBytes) override {
if (setjmp(png_jmpbuf(fCodec->fPng_ptr))) {
- SkDebugf("setjmp long jump!\n");
+ SkCodecPrintf("setjmp long jump!\n");
return SkImageGenerator::kInvalidInput;
}
@@ -522,7 +522,7 @@ public:
// FIXME: Could we use the return value of setjmp to specify the type of
// error?
if (setjmp(png_jmpbuf(fCodec->fPng_ptr))) {
- SkDebugf("setjmp long jump!\n");
+ SkCodecPrintf("setjmp long jump!\n");
return SkImageGenerator::kInvalidInput;
}
@@ -552,7 +552,7 @@ SkScanlineDecoder* SkPngCodec::onGetScanlineDecoder(const SkImageInfo& dstInfo)
}
if (!conversion_possible(dstInfo, this->getInfo())) {
- SkDebugf("no conversion possible\n");
+ SkCodecPrintf("no conversion possible\n");
return NULL;
}
@@ -563,7 +563,7 @@ SkScanlineDecoder* SkPngCodec::onGetScanlineDecoder(const SkImageInfo& dstInfo)
// FIXME: Pass this in to getScanlineDecoder?
opts.fZeroInitialized = kNo_ZeroInitialized;
if (this->initializeSwizzler(dstInfo, NULL, dstInfo.minRowBytes(), opts) != kSuccess) {
- SkDebugf("failed to initialize the swizzler.\n");
+ SkCodecPrintf("failed to initialize the swizzler.\n");
return NULL;
}
« no previous file with comments | « src/codec/SkCodec_libico.cpp ('k') | src/codec/SkMasks.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698