Skip to content

Commit

Permalink
Fix bug causing meshkernelpy test to fail
Browse files Browse the repository at this point in the history
  • Loading branch information
lucacarniato committed Dec 20, 2023
1 parent 56be2eb commit 1d1675b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libs/MeshKernelApi/src/MeshKernel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3444,8 +3444,8 @@ namespace meshkernelapi

*meshKernelState[meshKernelId].m_mesh2d += meshkernel::Mesh2D(edges, nodes, meshKernelState[meshKernelId].m_curvilinearGrid->m_projection);

// curvilinear grid must be reset
meshKernelState[meshKernelId].m_curvilinearGrid = nullptr;
// curvilinear grid must be reset to an empty curvilinear grid
meshKernelState[meshKernelId].m_curvilinearGrid = std::make_unique<meshkernel::CurvilinearGrid>();
}
catch (...)
{
Expand Down

0 comments on commit 1d1675b

Please sign in to comment.