From: Rosen Iliev Date: Wed, 30 Aug 2017 15:10:56 +0000 (+0300) Subject: Prevent crash when XInput is not present X-Git-Tag: v3.0.0~31^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8e5faec07c4db0c418c485806f83b087a93d21d4;p=platform%2Fcore%2Fcsapi%2Fopentk.git Prevent crash when XInput is not present Now returns from the function instead of throwing an exception --- diff --git a/src/OpenTK/Platform/Windows/XInputJoystick.cs b/src/OpenTK/Platform/Windows/XInputJoystick.cs index bf17115c..23d29d2c 100644 --- a/src/OpenTK/Platform/Windows/XInputJoystick.cs +++ b/src/OpenTK/Platform/Windows/XInputJoystick.cs @@ -381,7 +381,8 @@ namespace OpenTK.Platform.Windows } if (dll == IntPtr.Zero) { - throw new NotSupportedException("XInput was not found on this platform"); + //XInput was not found on this platform + return; } // Load the entry points we are interested in from that dll