Add lower-bound check to index for sample execution
このコミットが含まれているのは:
1 親
fd711db2e8
コミット
e28d8b30c0
1ファイル変更
+2
-2
@@ -56,14 +56,14 @@ class Program
|
||||
}
|
||||
while (!int.TryParse(Console.ReadLine(), out index));
|
||||
|
||||
if (index < Samples.Length)
|
||||
if (index >= 0 && index < Samples.Length)
|
||||
{
|
||||
Console.WriteLine();
|
||||
Console.WriteLine($"Starting {Samples[index].GetType().GenericTypeArguments[0].Name}...");
|
||||
|
||||
Win32ApplicationRunner.Run(Samples[index]);
|
||||
}
|
||||
} while (index < Samples.Length);
|
||||
} while (index >= 0 && index < Samples.Length);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
新しいイシューから参照
ユーザーをブロックする