mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-04-20 00:02:55 +00:00
ZoneCodeGenerator: When parsing open files in non-exclusive reading mode so other instances of ZoneCodeGenerator can run at the same time
This commit is contained in:
parent
63bbcfe5cb
commit
9e516cea1f
@ -44,7 +44,7 @@ namespace ZoneCodeGenerator.Parsing.Impl
|
|||||||
public IncludingStreamFileSystem(string path)
|
public IncludingStreamFileSystem(string path)
|
||||||
{
|
{
|
||||||
states = new Stack<HeaderStreamState>();
|
states = new Stack<HeaderStreamState>();
|
||||||
var initialState = new HeaderStreamState(new FileStream(path, FileMode.Open), path);
|
var initialState = new HeaderStreamState(new FileStream(path, FileMode.Open, FileAccess.Read, FileShare.Read), path);
|
||||||
|
|
||||||
states.Push(initialState);
|
states.Push(initialState);
|
||||||
}
|
}
|
||||||
@ -86,7 +86,7 @@ namespace ZoneCodeGenerator.Parsing.Impl
|
|||||||
|
|
||||||
if (!File.Exists(path)) return;
|
if (!File.Exists(path)) return;
|
||||||
|
|
||||||
var newState = new HeaderStreamState(new FileStream(path, FileMode.Open), path);
|
var newState = new HeaderStreamState(new FileStream(path, FileMode.Open, FileAccess.Read, FileShare.Read), path);
|
||||||
|
|
||||||
states.Push(newState);
|
states.Push(newState);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user