Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <jacques@blender.org>2021-03-07 16:27:08 +0300
committerJacques Lucke <jacques@blender.org>2021-03-07 16:27:08 +0300
commitc14770370f0f5906c479bb444f70a26733efade9 (patch)
treefb13bf9a85ec072cea53a1a560063071e4b2caa8 /source/blender/blenlib
parent649916f0983e4c59201672e6e28dcc7ae1f655b2 (diff)
Cleanup: fix implicit conversion warning
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r--source/blender/blenlib/BLI_linear_allocator.hh5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/blenlib/BLI_linear_allocator.hh b/source/blender/blenlib/BLI_linear_allocator.hh
index 0bf4ad194e1..47705b1d40b 100644
--- a/source/blender/blenlib/BLI_linear_allocator.hh
+++ b/source/blender/blenlib/BLI_linear_allocator.hh
@@ -215,8 +215,9 @@ template<typename Allocator = GuardedAllocator> class LinearAllocator : NonCopya
int64_t size_in_bytes = min_allocation_size;
if (size_in_bytes <= large_buffer_threshold) {
/* Gradually grow buffer size with each allocation, up to a maximum. */
- const int64_t grow_size = 1 << std::min<int64_t>(owned_buffers_.size() + 6, 20);
- size_in_bytes = std::min(large_buffer_threshold, std::max(size_in_bytes, grow_size));
+ const int grow_size = 1 << std::min<int>(owned_buffers_.size() + 6, 20);
+ size_in_bytes = std::min(large_buffer_threshold,
+ std::max<int64_t>(size_in_bytes, grow_size));
}
void *buffer = allocator_.allocate(size_in_bytes, min_alignment, __func__);