Skip to content

Commit

Permalink
[F] LoadFromPacked Occupying file
Browse files Browse the repository at this point in the history
  • Loading branch information
clansty committed Nov 25, 2024
1 parent 07631e9 commit 0ec048c
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@ namespace AquaMai.Config.HeadlessLoader;
public class HeadlessConfigLoader
{
public static HeadlessConfigInterface LoadFromPacked(string fileName)
=> LoadFromPacked(new FileStream(fileName, FileMode.Open));
{
using var file = new FileStream(fileName, FileMode.Open);
return LoadFromPacked(file);
}

public static HeadlessConfigInterface LoadFromPacked(byte[] assemblyBinary)
=> LoadFromPacked(new MemoryStream(assemblyBinary));
Expand Down

0 comments on commit 0ec048c

Please sign in to comment.