diff --git a/indra/llfilesystem/lldiskcache.cpp b/indra/llfilesystem/lldiskcache.cpp
index c9f7684b5a6e08bfbee396531aa95a5e0f0b7251..241c46dc735eabf57a849a774e059825beea1567 100644
--- a/indra/llfilesystem/lldiskcache.cpp
+++ b/indra/llfilesystem/lldiskcache.cpp
@@ -40,7 +40,7 @@
 #include "lldiskcache.h"
 
 LLDiskCache::LLDiskCache(const std::string cache_dir,
-                         const int max_size_bytes,
+                         const uintmax_t max_size_bytes,
                          const bool enable_cache_debug_info) :
     mCacheDir(cache_dir),
     mMaxSizeBytes(max_size_bytes),
diff --git a/indra/llfilesystem/lldiskcache.h b/indra/llfilesystem/lldiskcache.h
index 997884da319c8d4ecb53ca427c8ad6ea5fa9a827..c19714434a9ce616c260f6b1104b4328f4bd8450 100644
--- a/indra/llfilesystem/lldiskcache.h
+++ b/indra/llfilesystem/lldiskcache.h
@@ -86,7 +86,7 @@ class LLDiskCache :
                      * The maximum size of the cache in bytes - Based on the
                      * setting at 'CacheSize' and 'DiskCachePercentOfTotal'
                      */
-                    const int max_size_bytes,
+                    const uintmax_t max_size_bytes,
                     /**
                      * A flag that enables extra cache debugging so that
                      * if there are bugs, we can ask uses to enable this
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp
index a3d20a8e2f277babeb6c74b81bf994564e327aca..c519e55fc343c2350ae024639a045c4bf09f671a 100644
--- a/indra/newview/llappviewer.cpp
+++ b/indra/newview/llappviewer.cpp
@@ -4141,7 +4141,7 @@ bool LLAppViewer::initCache()
     const unsigned int cache_total_size_mb = gSavedSettings.getU32("CacheSize");
     const double disk_cache_percent = gSavedSettings.getF32("DiskCachePercentOfTotal");
     const unsigned int disk_cache_mb = cache_total_size_mb * disk_cache_percent / 100;
-    const unsigned int disk_cache_bytes = disk_cache_mb * 1024 * 1024;
+    const uintmax_t disk_cache_bytes = disk_cache_mb * 1024 * 1024;
 	const bool enable_cache_debug_info = gSavedSettings.getBOOL("EnableDiskCacheDebugInfo");
 
 	bool texture_cache_mismatch = false;