rhatlapa / pdfrecompressor

Automatically exported from code.google.com/p/pdfrecompressor
0 stars 0 forks source link

Deadlock on Windows #4

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Run program on Windows with std arguments: -pathToEnc d:\eco\jbig2.exe 
-input d:\eco\testJbIm.PDF -output d:\eco\testJbImOut.PDF -basename 
d:\Eco\output
2. Program JBIG2.exe is waiting forever

What is the expected output? What do you see instead?
- Java does not exit.
- Also the basename has to be provided because default is UNIX and the paths 
are combined with a path separator '/'

What version of the product are you using? On what operating system?
Tested with content of /trunk and content of /branches/pdfRecompressor
on Windows 7 x64

The problem is in jbig2enc.java, the program waits forever on prl.waitFor.

Moving this waitFor after the while to read errorStream fix the problem 
(deadlock)

Original issue reported on code.google.com by gui.g...@gmail.com on 11 Mar 2013 at 5:41

rhatlapa commented 8 years ago

This issue should be fixed by https://github.com/rhatlapa/pdfjbim/commit/cdac70e8d83c300d5a51bea9afaf858e9a029f94