I get the same "error" with 2.0.29. Tilman
On 20.09.2023 17:00, Morten Stulen wrote:
After upgrading to PDFBox 3, the PreflightParser.validate() function returns an error. "Trailer Syntax error, /XRef cross reference streams are not allowed" Code: fun isValid(bytes: ByteArray): Boolean { val fileName = "tmp_${UUID.randomUUID()}.pdf" val file = File(fileName) val document = Loader.loadPDF(bytes) document.save(fileName) // This returns a ValidationError val result = PreflightParser.validate(file) return result.isValid } The tested PDFs are the same as before the upgrade. ᐧ
--------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@pdfbox.apache.org For additional commands, e-mail: users-h...@pdfbox.apache.org