[ https://issues.apache.org/jira/browse/PDFBOX-1300?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13271487#comment-13271487 ]
Tanya Mays commented on PDFBOX-1300: ------------------------------------ Hi, I cannot see the number on the pdf i understand that it is constracted in parseDirObject(BaseParser.java:1084) method I am confirming with my company if i am allowed to send out the pdf for security reasons. if i could figure out the paragraph on which its happening i then i could send you just the paragraph. How can i figure this out ? Out of 1,200 documents i tried to convert to text , 139 had this error. Thank you for you help Tanya > COSNumber cannot convert numbers to long > ----------------------------------------- > > Key: PDFBOX-1300 > URL: https://issues.apache.org/jira/browse/PDFBOX-1300 > Project: PDFBox > Issue Type: Bug > Components: Parsing > Reporter: tatsiana mays > > in COSNumber.java if number passed is greater then long > 9,223,372,036,854,775,807. This is what i have > 2514740409086472832680141218906112. The method below cannot hadle > Need to do some extra else if loop > public static COSNumber get( String number ) throws IOException > { > if (number.length() == 1) { > char digit = number.charAt(0); > if ('0' <= digit && digit <= '9') { > return COSInteger.get(digit - '0'); > } else if (digit == '-' || digit == '.') { > // See https://issues.apache.org/jira/browse/PDFBOX-592 > return COSInteger.ZERO; > } else { > throw new IOException("Not a number: " + number); > } > } else if (number.indexOf('.') == -1 && number.length() < 19) { > try > { > return COSInteger.get( Long.parseLong( number ) ); > } > catch( NumberFormatException e ) > { > throw new IOException( "Value is not an integer: " + number ); > } > } else { > return new COSFloat(number); > } > } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira