On Mon, 2017-02-20 at 08:15 +0300, Nikita Shlyapnikov wrote:
> Files are easy enough to reproduce -  just modify any correct PDF
> file with a text editor able to save it correctly (like Notepad++). 
> Increase the value after the 'startxref' (adding a couple of zeroes
> at the end should suffice). 

        Hi,
I wanted to finally look on your patch and I realized that if I remove
all the white-space change noise, then it can be shrunk to the
attachment, which looks to me (if I do not miss anything) that the
change doesn't do anything real.

I suggest to test with the latest trunk, currently revision 1851. There
had been done some semi-related changes, which may or may not influence
what you see.
        Thanks and bye,
        zyx

-- 
http://www.litePDF.cz                                 i...@litepdf.cz
--- /tmp/PdfParser.cpp.old	2017-06-04 14:28:08.978696428 +0200
+++ /tmp/PdfParser.cpp.new	2017-06-04 14:27:56.357696602 +0200
@@ -617,7 +617,7 @@ void PdfParser::ReadTrailer()
     }
 }
 
-void PdfParser::ReadXRef( pdf_long* pXRefOffset )
+void PdfParser::FindXRef()
 {
     FindToken( "startxref", PDF_XREF_BUF );
 
@@ -630,11 +630,17 @@ void PdfParser::ReadXRef( pdf_long* pXRe
 			{
 				PODOFO_RAISE_ERROR( ePdfError_NoXRef );
 			}
-		} else 
+        }
+        else
 		{
 			PODOFO_RAISE_ERROR( ePdfError_NoXRef );
 		}
     }
+}
+
+void PdfParser::ReadXRef( pdf_long* pXRefOffset )
+{
+    FindXRef();
     *pXRefOffset = this->GetNextNumber();
 }
 
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Podofo-users mailing list
Podofo-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/podofo-users

Reply via email to