Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Divide by 0 when image is fully black #3

Open
pablojr opened this issue Jul 11, 2014 · 1 comment
Open

Divide by 0 when image is fully black #3

pablojr opened this issue Jul 11, 2014 · 1 comment

Comments

@pablojr
Copy link

pablojr commented Jul 11, 2014

Accidentally the leather cover was over the camera lens, so the image was fully black, and the embedding process ended up throwing an exception:

D/***************** JPEG-STEGO ******************(17749): Embedding of 1432 bits (175+4 bytes) 
D/***************** JPEG-STEGO ******************(17749): using default code, file will not fit
D/***************** JPEG-STEGO ******************(17749): 4 coefficients examined
E/***************** JPEG-STEGO ******************(17749): java.lang.ArithmeticException: divide by zero
W/System.err(17749): java.lang.ArithmeticException: divide by zero
W/System.err(17749):    at james.JpegEncoder.WriteCompressedData(JpegEncoder.java:577)
W/System.err(17749):    at james.JpegEncoder.Compress(JpegEncoder.java:93)
W/System.err(17749):    at james.JpegEncoder.Compress(JpegEncoder.java:113)
W/System.err(17749):    at info.guardianproject.f5android.Embed.<init>(Embed.java:84)
W/System.err(17749):    at info.guardianproject.f5android.Embed.<init>(Embed.java:41)
W/System.err(17749):    at com.mayorante.ztegocam.F5Embedder.doF5(F5Embedder.java:79)
W/System.err(17749):    at com.mayorante.ztegocam.F5Embedder.embed(F5Embedder.java:63)
W/System.err(17749):    at dalvik.system.NativeStart.run(Native Method)
@harlo
Copy link
Owner

harlo commented Jul 11, 2014

great catch, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants