diff options
author | Brecht Van Lommel <brecht@blender.org> | 2021-05-19 01:55:22 +0300 |
---|---|---|
committer | Brecht Van Lommel <brecht@blender.org> | 2021-05-19 19:30:43 +0300 |
commit | 0456223cde98712c16cb9b584b5c66c58ec915c3 (patch) | |
tree | 50fc8cfb9553102ae7d2bb9f6f7d62474fbe179f /intern/cycles/util | |
parent | 3e472d87a8d13aee078e156d584cf2171ed2d8a3 (diff) |
Fix T87793: Cycles OptiX crash hiding objects in viewport render
Diffstat (limited to 'intern/cycles/util')
-rw-r--r-- | intern/cycles/util/util_vector.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/intern/cycles/util/util_vector.h b/intern/cycles/util/util_vector.h index 04fb33368d9..87cd4de8438 100644 --- a/intern/cycles/util/util_vector.h +++ b/intern/cycles/util/util_vector.h @@ -43,8 +43,8 @@ class vector : public std::vector<value_type, allocator_type> { /* Try as hard as possible to use zero memory. */ void free_memory() { - BaseClass::resize(0); - BaseClass::shrink_to_fit(); + vector<value_type, allocator_type> empty; + BaseClass::swap(empty); } /* Some external API might demand working with std::vector. */ |