aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorGravatar reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2010-12-20 19:46:07 +0000
committerGravatar reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2010-12-20 19:46:07 +0000
commit0770044da6d61dcbc8d9673fed8dd92460faa314 (patch)
tree922e024c9b2590dc38384c9244c2f32114c4eeb7 /src
parent1f0869833933d7f672a4fc46e66078545f4c87dc (diff)
add option to write PDFs from gm
fix some compile warnings (reorder initializers, init local ptr) git-svn-id: http://skia.googlecode.com/svn/trunk@642 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src')
-rw-r--r--src/pdf/SkPDFDevice.cpp6
-rw-r--r--src/pdf/SkPDFImage.cpp2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/pdf/SkPDFDevice.cpp b/src/pdf/SkPDFDevice.cpp
index 9aefd0a258..fec9a4f883 100644
--- a/src/pdf/SkPDFDevice.cpp
+++ b/src/pdf/SkPDFDevice.cpp
@@ -131,10 +131,10 @@ static inline SkBitmap makeABitmap(int width, int height) {
}
SkPDFDevice::SkPDFDevice(int width, int height)
- : fWidth(width),
+ : SkDevice(NULL, makeABitmap(width, height), false),
+ fWidth(width),
fHeight(height),
- fGraphicStackIndex(0),
- SkDevice(NULL, makeABitmap(width, height), false) {
+ fGraphicStackIndex(0) {
fGraphicStack[0].fColor = SK_ColorBLACK;
fGraphicStack[0].fTextSize = SK_ScalarNaN; // This has no default value.
fGraphicStack[0].fTextScaleX = SK_Scalar1;
diff --git a/src/pdf/SkPDFImage.cpp b/src/pdf/SkPDFImage.cpp
index 65b9b24514..2162eaec66 100644
--- a/src/pdf/SkPDFImage.cpp
+++ b/src/pdf/SkPDFImage.cpp
@@ -29,7 +29,7 @@
namespace {
SkMemoryStream* extractImageData(const SkBitmap& bitmap) {
- SkMemoryStream* result;
+ SkMemoryStream* result = NULL;
bitmap.lockPixels();
switch (bitmap.getConfig()) {