mirror of
https://github.com/velopack/velopack.git
synced 2025-10-25 15:19:22 +00:00
Ignore processes that we don't have permission to get the name. Fixes #1024
This commit is contained in:
@@ -597,7 +597,7 @@ namespace Squirrel
|
||||
// Finally, clean up the app-X.Y.Z directories
|
||||
await toCleanup.ForEachAsync(async x => {
|
||||
try {
|
||||
if (runningProcesses.All(p => !p.Item1.StartsWith(x.FullName, StringComparison.OrdinalIgnoreCase))) {
|
||||
if (runningProcesses.All(p => p.Item1 == null || !p.Item1.StartsWith(x.FullName, StringComparison.OrdinalIgnoreCase))) {
|
||||
await Utility.DeleteDirectoryOrJustGiveUp(x.FullName);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user