mirror of
https://github.com/Redot-Engine/redot-engine.git
synced 2025-12-06 07:17:42 -05:00
Merge commit godotengine/godot@88b9932ce1
This commit is contained in:
@@ -61,11 +61,7 @@ private:
|
||||
}
|
||||
count = p_size;
|
||||
} else if (p_size > count) {
|
||||
if (unlikely(p_size > capacity)) {
|
||||
capacity = tight ? p_size : nearest_power_of_2_templated(p_size);
|
||||
data = (T *)memrealloc(data, capacity * sizeof(T));
|
||||
CRASH_COND_MSG(!data, "Out of memory");
|
||||
}
|
||||
reserve(p_size);
|
||||
if constexpr (p_init) {
|
||||
memnew_arr_placement(data + count, p_size - count);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user