Skip to content

Commit

Permalink
[hdSt] Reset renderPassStates and renderPasses before Hgi is deleted in
Browse files Browse the repository at this point in the history
HdSt_TestDriverBase, as they hold references to allocated buffers.

(Internal change: 2238233)
  • Loading branch information
clach authored and pixar-oss committed Jun 25, 2022
1 parent 35f03ad commit d3cd39f
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pxr/imaging/hdSt/unitTestHelper.h
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,14 @@ HdSt_TestDriverBase<SceneDelegate>::HdSt_TestDriverBase()
template<typename SceneDelegate>
HdSt_TestDriverBase<SceneDelegate>::~HdSt_TestDriverBase()
{
for (size_t i = 0; i < _renderPassStates.size(); i++) {
_renderPassStates[i].reset();
}

for (size_t i = 0; i < _renderPasses.size(); i++) {
_renderPasses[i].reset();
}

delete _sceneDelegate;
delete _renderIndex;
}
Expand Down

0 comments on commit d3cd39f

Please sign in to comment.