Hi,
Nice find. I suspect that he made the same change in JBIG2Filter than in
JPXFilter where it made sense
https://svn.apache.org/viewvc?view=revision&sortby=date&revision=1571082
I'll remove it and then run all tests, just to be sure.
Tilman
Am 28.02.2018 um 19:48 schrieb Itai:
Hello,
I was looking over the filters while trying to hack in some feature that I
need, and I came across something that to me seems like a bug.
Looking at JBIG2Filter, in lines 73-74 you have:
DecodeResult result = new DecodeResult(new COSDictionary());
result.getParameters().addAll(parameters);
The only other reference to `result` is towards the end of the `decode`
method (lines 136-139):
if (!parameters.containsKey(COSName.COLORSPACE))
{
result.getParameters().setName(COSName.COLORSPACE,
COSName.DEVICEGRAY.getName());
}
However, the actual return statement is (line 141):
return new DecodeResult(parameters);
So it seems that `result` isn't actually used or needed.
Is this a bug, and the return statement should return `result`? or is there
some way in which `result` does influence `parameters`, and thus is not
unnecessary?
Thanks,
Itai.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org