Skip to content

Commit

Permalink
Merge pull request #4262 from Sonicadvance1/fix_fileleak
Browse files Browse the repository at this point in the history
Windows/CRT: Fixes FD leak
  • Loading branch information
lioncash authored Jan 10, 2025
2 parents 90db948 + 4c9adab commit a18b2d0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Source/Windows/Common/CRT/IO.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ struct FILE {
: Handle {Handle}
, FileHandle {FileHandle}
, Append {Append} {}

~FILE() {
CloseHandle(Handle);
}
};

namespace {
Expand Down

0 comments on commit a18b2d0

Please sign in to comment.