Skip to content

Commit

Permalink
Windows/CRT: Fixes FD leak
Browse files Browse the repository at this point in the history
Noticed that the FEXCore config file was open forever.
  • Loading branch information
Sonicadvance1 committed Jan 9, 2025
1 parent 2293d30 commit 4c9adab
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 4c9adab

Please sign in to comment.