Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4eeb4fe9 authored by Thomas Makin's avatar Thomas Makin Committed by Ian Baker
Browse files

ExifInterface: do not spam stacktrace on invalid format

If we scan a directory with "unsupported" files, we get spam
stacktraces.

This is Debug at best.

Also simplify the error so it doesn't drift out of date with reality.
ExifInterface now supports reading more than just JPEG and RAW files,
see class-level javadoc for the latest list of supported formats.

Change-Id: I18e0b10ad735c9ce5696a2ad79f7551203c39d92
parent ed8c91e4
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -2037,9 +2037,10 @@ public class ExifInterface {
            // Ignore exceptions in order to keep the compatibility with the old versions of
            // ExifInterface.
            mIsSupportedFile = false;
            Log.w(TAG, "Invalid image: ExifInterface got an unsupported image format file"
                    + "(ExifInterface supports JPEG and some RAW image formats only) "
                    + "or a corrupted JPEG file to ExifInterface.", e);
            Log.d(
                    TAG,
                    "Invalid image: ExifInterface got an unsupported or corrupted image file",
                    e);
        } finally {
            addDefaultValuesForCompatibility();