Skip to content

Commit

Permalink
Don't clone AIPath objects at loading time.
Browse files Browse the repository at this point in the history
  • Loading branch information
pzgulyas committed Dec 12, 2021
1 parent c457f11 commit 57e5143
Showing 1 changed file with 2 additions and 3 deletions.
Expand Up @@ -1160,7 +1160,7 @@ public bool PreProcessRoutes(CancellationToken cancellation)
{
// read route
bool pathValid = true;
LoadPathNoClone(thisRoute, out pathValid);
LoadPath(thisRoute, out pathValid);
if (!pathValid) allPathsLoaded = false;
if (cancellation.IsCancellationRequested)
return (false);
Expand All @@ -1176,8 +1176,7 @@ public bool PreProcessRoutes(CancellationToken cancellation)
/// <param name="pathstring"></param>
/// <param name="validPath"></param>
/// <returns></returns>
public AIPath LoadPath(string pathstring, out bool validPath) => new AIPath(LoadPathNoClone(pathstring, out validPath));
public AIPath LoadPathNoClone(string pathstring, out bool validPath)
public AIPath LoadPath(string pathstring, out bool validPath)
{
validPath = true;

Expand Down

0 comments on commit 57e5143

Please sign in to comment.