comparison ServerMonitor/Objects/Checks/SshCheck.cs @ 39:7645122aa7a9

Get it working under Mono
author Brad Greco <brad@bgreco.net>
date Tue, 09 Jun 2020 20:59:00 -0400
parents 68d7834dc28e
children
comparison
equal deleted inserted replaced
38:8ab98a803d39 39:7645122aa7a9
115 message += "At least one check must be enabled." + Environment.NewLine; 115 message += "At least one check must be enabled." + Environment.NewLine;
116 if (CheckCommandOutput && CommandOutputUseRegex) 116 if (CheckCommandOutput && CommandOutputUseRegex)
117 { 117 {
118 try 118 try
119 { 119 {
120 Regex re = new Regex(CommandOutputPattern); 120 new Regex(CommandOutputPattern);
121 } 121 }
122 catch (ArgumentException) 122 catch (ArgumentException)
123 { 123 {
124 message += "Invalid regular expression for command output." + Environment.NewLine; 124 message += "Invalid regular expression for command output." + Environment.NewLine;
125 } 125 }