Viewing 1 post (of 1 total)
  • Author
  • #27204


    Referring to an older subject pdf-generation-troubleshooting-f4/broken-png-image-file-hangs-pd4ml-generator-forever-t650.html

    We see this kind of problems still (or again)?

    There is code i PD4ML that gets the size of an image, and if width is < 0, it waits 10 ms and then tries again. Forever... In our web app, this happens regularly. Probably this is with a PNG image that Java considers bad in some way. The code (disassembled obfuscated code) looks like this: <br /> public final PixelGrabber new(int var1) {<br /> int var2 = this.Ö00000.getHeight(this.ø00000);<br /> int var3 = this.Ö00000.getWidth(this.ø00000);<br /> <br /> while(var2 < 0) {<br /> var2 = this.Ö00000.getHeight(this.ø00000);<br /> var3 = this.Ö00000.getWidth(this.ø00000);<br /> if (this.ÒO0000 != null && this.ÒO0000.length() > 4 && this.ÒO0000.substring(0, 5).toLowerCase().equals("data:")) {<br /> var2 = 1;<br /> var3 = 1;<br /> this.Ö00000 = new BufferedImage(1, 1, 2);<br /> break;<br /> }<br /> <br /> try {<br /> Thread.sleep(10L);<br /> } catch (InterruptedException var14) {<br /> ;<br /> }<br /> }<br /> The inifinte loop here is the problem. I see two problems here, one beeing the infinite loop, the other being that it ignores the InterruptedException. You should probablty give up here and just add a "broken image" after a number of iterations? Please advise, can we trust PD4ML to handle this some way, or do we need to change to another library? Best regards, Palle Girgensohn

Viewing 1 post (of 1 total)

The forum ‘Troubleshooting’ is closed to new topics and replies.