pdfviewer: remove debug traces
authoredisonn@google.com <edisonn@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Mon, 5 Aug 2013 22:08:50 +0000 (22:08 +0000)
committeredisonn@google.com <edisonn@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Mon, 5 Aug 2013 22:08:50 +0000 (22:08 +0000)
Review URL: https://codereview.chromium.org/22284004

git-svn-id: http://skia.googlecode.com/svn/trunk@10551 2bbb7eff-a529-9590-31e7-b0007b416f81

experimental/PdfViewer/SkPdfRenderer.cpp
experimental/PdfViewer/pdfparser/native/SkPdfNativeTokenizer.cpp

index bb2049e..4d9b964 100644 (file)
@@ -311,13 +311,6 @@ static bool readToken(SkPdfNativeTokenizer* fTokenizer, PdfToken* token) {
         out.appendf("/usr/local/google/home/edisonn/log_view2/step-%i-%s.png", gLastOpKeyword, gLastKeyword);
         SkImageEncoder::EncodeFile(out.c_str(), bitmap, SkImageEncoder::kPNG_Type, 100);
     }
-
-    if (token->fType == kKeyword_TokenType) {
-        strcpy(gLastKeyword, token->fKeyword);
-        gLastOpKeyword = gReadOp;
-    } else {
-        strcpy(gLastKeyword, "");
-    }
 #endif
 
     return ret;
index a888138..00861a5 100644 (file)
@@ -932,7 +932,6 @@ bool SkPdfNativeTokenizer::readTokenCore(PdfToken* token) {
     SkPdfObject obj;
 #ifdef PDF_TRACE_READ_TOKEN
     static int read_op = 0;
-    int last;
 #endif
     token->fKeyword = NULL;
     token->fObject = NULL;
@@ -942,18 +941,7 @@ bool SkPdfNativeTokenizer::readTokenCore(PdfToken* token) {
         return false;
     }
 
-#ifdef PDF_TRACE_READ_TOKEN
-    printf("BEFORE the read: %i\n", read_op);
-    last = read_op;
-#endif
-
     fUncompressedStream = nextObject(0, fUncompressedStream, fUncompressedStreamEnd, &obj, fAllocator, fDoc);
-#ifdef PDF_TRACE_READ_TOKEN
-    printf("BEFORE the read: %i\n", read_op);
-    if (last != read_op) {
-        printf("break; // memory override");
-    }
-#endif
 
     // If it is a keyword, we will only get the pointer of the string
     if (obj.type() == SkPdfObject::kKeyword_PdfObjectType) {