Skip to content

Commit

Permalink
APREPRO: Fix the memory leak fix
Browse files Browse the repository at this point in the history
  • Loading branch information
gsjaardema committed Aug 3, 2023
1 parent af29b8b commit 5a1fea6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/seacas/libraries/aprepro_lib/apr_aprepro.cc
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ namespace SEAMS {
{
if (!outputStream.empty()) {
outputStream.top()->flush();
delete outputStream.top();
if (outputStream.size() > 1) {
std::ostream *output = outputStream.top();
delete output;
}
}

// May need to delete this if set via --info=filename command.
Expand Down

0 comments on commit 5a1fea6

Please sign in to comment.