Corrected an error, where keysyms were not allocated, causing an NRE.

This commit is contained in:
the_fiddler 2007-08-05 16:19:25 +00:00
parent 25f82c8b84
commit 2b7f7bbc24

View file

@ -107,7 +107,7 @@ namespace OpenTK.Platform.X11
IntPtr keysym_ptr = API.GetKeyboardMapping(window.Display, (byte)firstKeyCode,
lastKeyCode - firstKeyCode + 1, ref keysyms_per_keycode);
Marshal.PtrToStructure(keysym_ptr, keysyms);
keysyms = (IntPtr[])Marshal.PtrToStructure(keysym_ptr, typeof(IntPtr[]));
API.Free(keysym_ptr);
}