Issue 1:
I use Glide to view thumbnails of pictures and videos like 3.5GB in the gallery. Glide crashes while uploading high size video image after 4.11.0 update.

Glide Version: 4.11.0, 4.12.0

Integration libraries: 'com.squareup.okhttp3:okhttp:3.11.0'

Device/Android Version: Huawei P30 Pro

Issue details / Repro steps / Use case background: Glide crashes when I want to view thumbnails of large videos in the gallery.

Glide load line / GlideModule (if any) / list Adapter code (if any):

GlideApp.with(this).load(media.getPath())
.diskCacheStrategy(DiskCacheStrategy.NONE)
.transition(DrawableTransitionOptions.withCrossFade())
.into(thumbnail);

Layout XML:

<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginEnd="2dp"
android:layout_marginRight="2dp"
android:layout_marginBottom="2dp"
android:animateLayoutChanges="true">

<com.chat.android.util.view.SquareImageView
android:id="@+id/mediapicker_image_item_thumbnail"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:adjustViewBounds="true"
android:scaleType="centerCrop" />

Stack trace / LogCat:

2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #33 pc 0000000000325d28 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.ParcelFileDescriptorBitmapDecoder.decode+4)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #36 pc 0000000000325d48 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.ParcelFileDescriptorBitmapDecoder.decode+4)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #39 pc 0000000000314dca [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodePath.decodeResourceWithList+66)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #42 pc 0000000000314d48 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodePath.decodeResource+36)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #45 pc 0000000000314cf4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodePath.decode)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #48 pc 000000000031768a [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.LoadPath.loadWithExceptionList+66)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #51 pc 000000000031760a [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.LoadPath.load+38)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #54 pc 0000000000314404 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runLoadPath+52)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #57 pc 00000000003141f4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromFetcher+20)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #60 pc 000000000031416e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromData+22)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #63 pc 00000000003145d0 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromRetrievedData+124)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #66 pc 00000000003148d6 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.onDataFetcherReady+98)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #69 pc 00000000003185a2 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.onDataReadyInternal+86)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #72 pc 00000000003181e4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator$1.onDataReady+28)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #75 pc 0000000000311ed0 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.data.LocalUriFetcher.loadData+20)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #78 pc 0000000000318626 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNextLoad+30)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #81 pc 0000000000318350 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNext+200)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #84 pc 0000000000314b7e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runGenerators+46)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #87 pc 000000000031460a [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromRetrievedData+182)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #90 pc 00000000003148d6 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.onDataFetcherReady+98)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #93 pc 00000000003185a2 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.onDataReadyInternal+86)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #96 pc 00000000003181e4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator$1.onDataReady+28)
2021-03-09 08:20:16.052 14897-14897/? A/DEBUG: #99 pc 0000000000311ed0 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.data.LocalUriFetcher.loadData+20)
2021-03-09 08:20:16.053 14897-14897/? A/DEBUG: #102 pc 0000000000318626 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNextLoad+30)
2021-03-09 08:20:16.053 14897-14897/? A/DEBUG: #105 pc 0000000000318350 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNext+200)
2021-03-09 08:20:16.053 14897-14897/? A/DEBUG: #108 pc 0000000000314b7e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runGenerators+46)
2021-03-09 08:20:16.053 14897-14897/? A/DEBUG: #111 pc 0000000000314c70 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runWrapped+132)
2021-03-09 08:20:16.053 14897-14897/? A/DEBUG: #114 pc 0000000000314a6e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.run+54)
2021-03-09 08:20:16.053 14897-14897/? A/DEBUG: #126 pc 000000000031c5ca [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.executor.GlideExecutor$DefaultThreadFactory$1.run+62)
2021-03-09 08:22:08.808 15063-15063/? A/DEBUG: pid: 14929, tid: 15058, name: glide-source-th >>> com.chat.android <<<
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #15 pc 00000000003259e6 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.ImageReader$ParcelFileDescriptorImageReader.decodeBitmap+22)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #18 pc 0000000000323e02 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.Downsampler.decodeStream+50)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #21 pc 0000000000324292 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.Downsampler.getDimensions+6)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #24 pc 0000000000323a0c [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.Downsampler.decodeFromWrappedStreams+28)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #27 pc 000000000032413e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.Downsampler.decode+222)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #30 pc 0000000000324046 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.Downsampler.decode+30)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #33 pc 0000000000325d28 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.ParcelFileDescriptorBitmapDecoder.decode+4)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #36 pc 0000000000325d48 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.resource.bitmap.ParcelFileDescriptorBitmapDecoder.decode+4)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #39 pc 0000000000314dca [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodePath.decodeResourceWithList+66)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #42 pc 0000000000314d48 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodePath.decodeResource+36)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #45 pc 0000000000314cf4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodePath.decode)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #48 pc 000000000031768a [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.LoadPath.loadWithExceptionList+66)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #51 pc 000000000031760a [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.LoadPath.load+38)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #54 pc 0000000000314404 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runLoadPath+52)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #57 pc 00000000003141f4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromFetcher+20)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #60 pc 000000000031416e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromData+22)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #63 pc 00000000003145d0 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromRetrievedData+124)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #66 pc 00000000003148d6 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.onDataFetcherReady+98)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #69 pc 00000000003185a2 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.onDataReadyInternal+86)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #72 pc 00000000003181e4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator$1.onDataReady+28)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #75 pc 0000000000311ed0 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.data.LocalUriFetcher.loadData+20)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #78 pc 0000000000318626 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNextLoad+30)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #81 pc 0000000000318350 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNext+200)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #84 pc 0000000000314b7e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runGenerators+46)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #87 pc 000000000031460a [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.decodeFromRetrievedData+182)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #90 pc 00000000003148d6 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.onDataFetcherReady+98)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #93 pc 00000000003185a2 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.onDataReadyInternal+86)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #96 pc 00000000003181e4 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator$1.onDataReady+28)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #99 pc 0000000000311ed0 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.data.LocalUriFetcher.loadData+20)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #102 pc 0000000000318626 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNextLoad+30)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #105 pc 0000000000318350 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.SourceGenerator.startNext+200)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #108 pc 0000000000314b7e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runGenerators+46)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #111 pc 0000000000314c70 [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.runWrapped+132)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #114 pc 0000000000314a6e [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.DecodeJob.run+54)
2021-03-09 08:22:08.937 15063-15063/? A/DEBUG: #126 pc 000000000031c5ca [anon:dalvik-classes.dex extracted in memory from /data/app/com.chat.android-FRmNaXcbtRtm3i_s4Ex6iQ==/base.apk] (com.bumptech.glide.load.engine.executor.GlideExecutor$DefaultThreadFactory$1.run+62)

Issue 2:
Glide Version: 4.11.0

Integration libraries: Default installation

Device/Android Version: Huawei p30 Android 10

Issue details / Repro steps / Use case background:

Closes (crashes) the activity when try to load a big sized video file into an imageview. Running well with previous versions (4.10.0) Tested with 2Gb video file.

Glide load line / GlideModule (if any) / list Adapter code (if any):

Glide.with(mActivity)
.load(video_data.getContentUri())
.apply(options)
.transition(DrawableTransitionOptions.withCrossFade())
.centerCrop()
.into(holder.image_view_picture);

Stack trace / LogCat:

2020-03-30 16:15:43.677 1248-1364/cast.to.big A/libc: FORTIFY: read: count 18446744071704558641 > SSIZE_MAX
2020-03-30 16:15:43.677 1248-1364/cast.to.big A/libc: Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 1364 (glide-source-th), pid 1248 (cast.to.big)

It runs great if we use 4.10.0 Glide version instance of 4.11.0