diff options
| author | Bryan Galdrikian <[email protected]> | 2021-03-16 08:23:01 -0700 |
|---|---|---|
| committer | GitHub <[email protected]> | 2021-03-16 08:23:01 -0700 |
| commit | d7f11c36d9331e816782a60631ecc26a9a43fad1 (patch) | |
| tree | 5e8b1057e02954d8003ebff9fa97e4c1f403a842 /sdk | |
| parent | Merge pull request #18 from lgzy/fix-asset-joint-serialization (diff) | |
| parent | Fix index being out of bounds (diff) | |
| download | blast-d7f11c36d9331e816782a60631ecc26a9a43fad1.tar.xz blast-d7f11c36d9331e816782a60631ecc26a9a43fad1.zip | |
Merge pull request #19 from lgzy/fix-index-out-of-bounds
Fix index out of bounds
Diffstat (limited to 'sdk')
| -rwxr-xr-x | sdk/toolkit/source/NvBlastTkGroupImpl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sdk/toolkit/source/NvBlastTkGroupImpl.cpp b/sdk/toolkit/source/NvBlastTkGroupImpl.cpp index c3cbd5e..19f9747 100755 --- a/sdk/toolkit/source/NvBlastTkGroupImpl.cpp +++ b/sdk/toolkit/source/NvBlastTkGroupImpl.cpp @@ -293,9 +293,9 @@ bool TkGroupImpl::removeActor(TkActor& actor) {
uint32_t index = tkActor.m_groupJobIndex;
tkActor.m_groupJobIndex = invalidIndex<uint32_t>();
- m_jobs.replaceWithLast(index);
if (index < m_jobs.size())
{
+ m_jobs.replaceWithLast(index);
NVBLAST_ASSERT(m_jobs[index].m_tkActor->m_groupJobIndex == m_jobs.size());
NVBLAST_ASSERT(m_jobs[index].m_tkActor->isPending());
m_jobs[index].m_tkActor->m_groupJobIndex = index;
|