We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 294a829 commit f3a4725Copy full SHA for f3a4725
src/CommandLineUtils/IO/PhysicalConsole.cs
@@ -27,7 +27,18 @@ private PhysicalConsole()
27
public event ConsoleCancelEventHandler? CancelKeyPress
28
{
29
add => Console.CancelKeyPress += value;
30
- remove => Console.CancelKeyPress -= value;
+ remove
31
+ {
32
+ try
33
34
+ Console.CancelKeyPress -= value;
35
+ }
36
+ catch (PlatformNotSupportedException)
37
38
+ // https://github.com/natemcmaster/CommandLineUtils/issues/344
39
+ // Suppress this error during unsubscription on some Xamarin platforms.
40
41
42
}
43
44
/// <summary>
0 commit comments