summarylogtreecommitdiffstats
path: root/chromium-ffmpeg-4.3.patch
blob: 6abb886ab990f645c5cb2d8e99bc6c2f09b83aa0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
diff --git a/media/base/media.cc b/media/base/media.cc
index c282ee49a03..a298b40c79b 100644
--- a/media/base/media.cc
+++ b/media/base/media.cc
@@ -14,6 +14,7 @@
 #include "third_party/libyuv/include/libyuv.h"
 
 #if BUILDFLAG(ENABLE_FFMPEG)
+#include <limits>
 #include "third_party/ffmpeg/ffmpeg_features.h"  // nogncheck
 extern "C" {
 #include <libavutil/cpu.h>
@@ -41,7 +42,7 @@ class MediaInitializer {
 
 #if BUILDFLAG(USE_ALLOCATOR_SHIM)
     // Remove allocation limit from ffmpeg, so calls go down to shim layer.
-    av_max_alloc(0);
+    av_max_alloc(std::numeric_limits<size_t>::max());
 #endif  // BUILDFLAG(USE_ALLOCATOR_SHIM)
 
 #endif  // BUILDFLAG(ENABLE_FFMPEG)