Skip to content

Commit

Permalink
Protect against the exception if the content list doesn't exist.
Browse files Browse the repository at this point in the history
  • Loading branch information
tomspilman committed Apr 18, 2013
1 parent a3b0db9 commit 8a12ff1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Tools/MGCB/BuildContent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,8 @@ public void Build(out int successCount, out int errorCount)

// Delete the old file and write the new content
// list if we have any to serialize.
File.Delete(contentFile);
if (File.Exists(contentFile))
File.Delete(contentFile);
if (newContent.SourceFiles.Count > 0)
newContent.Write(contentFile);
}
Expand Down

0 comments on commit 8a12ff1

Please sign in to comment.