Skip to content

Commit

Permalink
vrtprocesseddataset.cpp: Add cppcheck suppression
Browse files Browse the repository at this point in the history
  • Loading branch information
dbaston committed Jan 10, 2025
1 parent c038111 commit d514839
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion frmts/vrt/vrtprocesseddataset.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,9 @@ CPLErr VRTProcessedDataset::Init(const CPLXMLNode *psTree,
auto *poArgs = GDALTranslateOptionsNew(oArgs.List(), nullptr);
int pbUsageError;
CPLAssert(poArgs);
m_poVRTSrcDS = std::move(m_poSrcDS);
m_poVRTSrcDS.reset(m_poSrcDS.release());
// https://trac.cppcheck.net/ticket/11325
// cppcheck-suppress accessMoved
m_poSrcDS.reset(GDALDataset::FromHandle(
GDALTranslate("", m_poVRTSrcDS.get(), poArgs, &pbUsageError)));
GDALTranslateOptionsFree(poArgs);
Expand Down

0 comments on commit d514839

Please sign in to comment.