提交 3b8a6273 编写于 作者: L Larry Golding

ProcessWatchdog: Check for existence of procdump.exe

上级 0b35f24f
......@@ -3,6 +3,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Threading;
......@@ -37,6 +38,12 @@ private int Run()
return 1;
}
if (!File.Exists(_options.ProcDumpPath))
{
ConsoleUtils.LogError(Resources.ErrorProcDumpNotFound, _options.ProcDumpPath);
return 1;
}
var processStartInfo = new ProcessStartInfo
{
FileName = _options.Executable,
......
......@@ -123,6 +123,15 @@ internal class Resources {
}
}
/// <summary>
/// Looks up a localized string similar to The procdump executable {0} was not found..
/// </summary>
internal static string ErrorProcDumpNotFound {
get {
return ResourceManager.GetString("ErrorProcDumpNotFound", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to The process {0} ({1}) or one of its descendants exceeded the time limit of {2} seconds. This process and all its descendants will be terminated..
/// </summary>
......
......@@ -138,6 +138,9 @@
<data name="ErrorInvalidTimeLimit" xml:space="preserve">
<value>The value {0} is not a valid time limit. Please specify the time limit as a positive number of seconds.</value>
</data>
<data name="ErrorProcDumpNotFound" xml:space="preserve">
<value>The procdump executable {0} was not found.</value>
</data>
<data name="ErrorProcessTimedOut" xml:space="preserve">
<value>The process {0} ({1}) or one of its descendants exceeded the time limit of {2} seconds. This process and all its descendants will be terminated.</value>
</data>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册