Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: Remove unreachable code in Common\OpenCL, after itkExceptionMacro #449

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion Common/OpenCL/ITKimprovements/itkGPUDataManager.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,6 @@ GPUDataManager::Update()
if (m_IsGPUBufferDirty && m_IsCPUBufferDirty)
{
itkExceptionMacro("Cannot make up-to-date buffer because both CPU and GPU buffers are dirty");
return false;
}

this->UpdateGPUBuffer();
Expand Down
4 changes: 0 additions & 4 deletions Common/OpenCL/ITKimprovements/itkOpenCLLogger.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,6 @@ OpenCLLogger::Initialize()
if (this->m_FileStream->fail())
{
itkExceptionMacro(<< "Unable to open file: " << logFileName);
delete this->m_FileStream;
this->m_FileStream = nullptr;
this->m_Created = false;
Comment on lines -107 to -109
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dpshamonin Do you happen to know, should these three lines of code (starting with delete this->m_FileStream) be placed before, instead of after the itkExceptionMacro call?

return;
}

// Create an ITK Logger
Expand Down