mirror of
https://github.com/MacosPorters/betterxen.git
synced 2026-11-26 19:30:43 +00:00
fopen created a missing file before it allocated the FILE object, so a failed allocation left an empty file behind. The FILE object is now allocated first and released again if the drive cannot take the file. A test fills the heap and checks that neither a new file appears nor an existing one loses its contents. Signed-off-by: zachdoxsee <zachdoxsee36@gmail.com>