[poppler] Branch 'poppler-0.18' - utils/pdftocairo.cc

Carlos Garcia Campos carlosgc at kemper.freedesktop.org
Sun Oct 30 08:10:31 PDT 2011


 utils/pdftocairo.cc |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 61b1556d1c62bf090b2eadf93e4e7d0aff7b8015
Author: Carlos Garcia Campos <carlosgc at gnome.org>
Date:   Sun Oct 30 16:08:46 2011 +0100

    pdftocairo: Use fisrtPage instead of uninitialized pg variable
    
    This fixes an error in my previous commit.

diff --git a/utils/pdftocairo.cc b/utils/pdftocairo.cc
index 1b67c90..d0d1ec6 100644
--- a/utils/pdftocairo.cc
+++ b/utils/pdftocairo.cc
@@ -904,7 +904,7 @@ int main(int argc, char *argv[]) {
   }
 
   // Make sure firstPage is always used so that beginDocument() is called
-  if ((printOnlyEven && pg % 2 == 0) || (printOnlyOdd && pg % 2 == 1))
+  if ((printOnlyEven && firstPage % 2 == 0) || (printOnlyOdd && firstPage % 2 == 1))
     firstPage++;
 
   cairoOut = new CairoOutputDev();


More information about the poppler mailing list