[jira] [Commented] (PDFBOX-4443) Error: End-of-File, expected line

2019-08-26 Thread toyokazu.ohara (Jira)


[ 
https://issues.apache.org/jira/browse/PDFBOX-4443?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16915603#comment-16915603
 ] 

toyokazu.ohara commented on PDFBOX-4443:


Tilman

Thank you for your advice!

I try it!

> Error: End-of-File, expected line
> -
>
> Key: PDFBOX-4443
> URL: https://issues.apache.org/jira/browse/PDFBOX-4443
> Project: PDFBox
>  Issue Type: Bug
>  Components: Parsing
>Affects Versions: 2.0.13
> Environment: Linux
>Reporter: Dinesh
>Priority: Critical
>  Labels: linux
>
> I am using the latest version of pdfbox.
> I am able to extraxt the file as normal stream in java 8 and open as pdf.
> But when try to load with pdfbox getting below error
> Getting this exception when filename is passed from shell script in linux.
> java.io.IOException: Error: End-of-File, expected line
>  at org.apache.pdfbox.pdfparser.BaseParser.readLine(BaseParser.java:1121) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parseHeader(COSParser.java:2574) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parsePDFHeader(COSParser.java:2553) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.PDFParser.parse(PDFParser.java:219) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1200) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1173) 
> ~[pdfbox-2.0.13.jar:2.0.13]



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4443) Error: End-of-File, expected line

2019-08-23 Thread toyokazu.ohara (Jira)


[ 
https://issues.apache.org/jira/browse/PDFBOX-4443?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16914792#comment-16914792
 ] 

toyokazu.ohara commented on PDFBOX-4443:


public static void main(String[] args) {
 
System.out.println(getString("https://www.fsa.go.jp/singi/monitoring/siryou/20160824/02.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/singi/monitoring/siryou/20160824/03.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/singi/monitoring/siryou/20160824/01.pdf;));
 System.out.println(getString("https://www.fsa.go.jp/menkyo/menkyoj/ihou.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/menkyo/menkyoj/chuui1.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/ordinary/chuui/chuui2.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/status/stewardship/kikan.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/choutatu/choutatu_j/31/190625.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/choutatu/choutatu_j/31/190607-2.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/choutatu/choutatu_j/31/20190422-1.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/choutatu/choutatu_j/31/20190405-2.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/choutatu/choutatu_j/31/190614-2.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/choutatu/choutatu_j/31/20190808.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/news/r1/kyokin/20190809/04.pdf;));
 
System.out.println(getString("https://www.fsa.go.jp/news/r1/kyokin/20190809/06.pdf;));
 }

public static String getString(String url) {
 try (PDDocument document = PDDocument.load(new URL(url).openStream())) {
 return "OK";
 } catch (IOException e) {
 return "error";
 }
 }

> Error: End-of-File, expected line
> -
>
> Key: PDFBOX-4443
> URL: https://issues.apache.org/jira/browse/PDFBOX-4443
> Project: PDFBox
>  Issue Type: Bug
>  Components: Parsing
>Affects Versions: 2.0.13
> Environment: Linux
>Reporter: Dinesh
>Priority: Critical
>  Labels: linux
>
> I am using the latest version of pdfbox.
> I am able to extraxt the file as normal stream in java 8 and open as pdf.
> But when try to load with pdfbox getting below error
> Getting this exception when filename is passed from shell script in linux.
> java.io.IOException: Error: End-of-File, expected line
>  at org.apache.pdfbox.pdfparser.BaseParser.readLine(BaseParser.java:1121) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parseHeader(COSParser.java:2574) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parsePDFHeader(COSParser.java:2553) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.PDFParser.parse(PDFParser.java:219) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1200) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1173) 
> ~[pdfbox-2.0.13.jar:2.0.13]



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4443) Error: End-of-File, expected line

2019-08-23 Thread toyokazu.ohara (Jira)


[ 
https://issues.apache.org/jira/browse/PDFBOX-4443?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16914790#comment-16914790
 ] 

toyokazu.ohara commented on PDFBOX-4443:


Tilman

thank you for your reply.

sorry about that.

 

it looks like that error occurs randomly.

please check attach file.

 

 

> Error: End-of-File, expected line
> -
>
> Key: PDFBOX-4443
> URL: https://issues.apache.org/jira/browse/PDFBOX-4443
> Project: PDFBox
>  Issue Type: Bug
>  Components: Parsing
>Affects Versions: 2.0.13
> Environment: Linux
>Reporter: Dinesh
>Priority: Critical
>  Labels: linux
>
> I am using the latest version of pdfbox.
> I am able to extraxt the file as normal stream in java 8 and open as pdf.
> But when try to load with pdfbox getting below error
> Getting this exception when filename is passed from shell script in linux.
> java.io.IOException: Error: End-of-File, expected line
>  at org.apache.pdfbox.pdfparser.BaseParser.readLine(BaseParser.java:1121) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parseHeader(COSParser.java:2574) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parsePDFHeader(COSParser.java:2553) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.PDFParser.parse(PDFParser.java:219) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1200) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1173) 
> ~[pdfbox-2.0.13.jar:2.0.13]



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4443) Error: End-of-File, expected line

2019-08-22 Thread toyokazu.ohara (Jira)


[ 
https://issues.apache.org/jira/browse/PDFBOX-4443?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16913633#comment-16913633
 ] 

toyokazu.ohara commented on PDFBOX-4443:


Hi!

I got same problem.

Tilman

please check these files.

https://www.fsa.go.jp/common/about/jinji/28/20161130.pdf
http://www.caa.go.jp/adjustments/pdf/110401adjustments_1.pdf
[https://www.fsa.go.jp/singi/monitoring/siryou/20160824/02.pdf]

> Error: End-of-File, expected line
> -
>
> Key: PDFBOX-4443
> URL: https://issues.apache.org/jira/browse/PDFBOX-4443
> Project: PDFBox
>  Issue Type: Bug
>  Components: Parsing
>Affects Versions: 2.0.13
> Environment: Linux
>Reporter: Dinesh
>Priority: Critical
>  Labels: linux
>
> I am using the latest version of pdfbox.
> I am able to extraxt the file as normal stream in java 8 and open as pdf.
> But when try to load with pdfbox getting below error
> Getting this exception when filename is passed from shell script in linux.
> java.io.IOException: Error: End-of-File, expected line
>  at org.apache.pdfbox.pdfparser.BaseParser.readLine(BaseParser.java:1121) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parseHeader(COSParser.java:2574) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.COSParser.parsePDFHeader(COSParser.java:2553) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdfparser.PDFParser.parse(PDFParser.java:219) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1200) 
> ~[pdfbox-2.0.13.jar:2.0.13]
>  at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1173) 
> ~[pdfbox-2.0.13.jar:2.0.13]



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org