Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
None
-
None
Description
[imported from SourceForge]
http://sourceforge.net/tracker/index.php?group_id=78314&atid=552832&aid=1483833
Originally submitted by gagravarr on 2006-05-08 07:05.
I'm using PDFBox 0.7.2. On a certain document
(http://www-wds.worldbank.org/external/default/WDSContentServer/IW3P/IB/2005/12/27/000160016_20051227181308/Rendered/PDF/E12860v10P096469EAs.pdf),
when I execute the following code:
PDFParser pdfParser = new PDFParser( docStream );
pdfParser.parse();
PDDocument pdfDocument = pdfParser.getPDDocument();
StringWriter textWriter = new StringWriter();
PDFTextStripper textStripper = new PDFTextStripper();
textStripper.writeText(pdfDocument, textWriter);
I get the following nasty stack trace from deep inside
PDFBox:
Exception in thread "main" java.util.EmptyStackException
at java.util.Stack.peek(Stack.java:79)
at java.util.Stack.pop(Stack.java:61)
at
org.pdfbox.util.operator.GRestore.process(GRestore.java:65)
at
org.pdfbox.util.PDFStreamEngine.processOperator(PDFStreamEngine.java:
494)
at
org.pdfbox.util.PDFStreamEngine.processSubStream(PDFStreamEngine.java
:207)
at
org.pdfbox.util.PDFStreamEngine.processStream(PDFStreamEngine.java:16
0)
at
org.pdfbox.util.PDFTextStripper.processPage(PDFTextStripper.java:355)
at
org.pdfbox.util.PDFTextStripper.processPages(PDFTextStripper.java:268
)
at
org.pdfbox.util.PDFTextStripper.writeText(PDFTextStripper.java:220)
Attachments
Attachments
Issue Links
- is related to
-
PDFBOX-1812 Illegal characters in XML output
- Closed
-
PDFBOX-2214 EmptyStackException in PDFStreamEngine
- Closed