Re: [libvirt] [PATCH 1/2] Fix keymap used to talk with QEMU

2011-08-26 Thread Daniel P. Berrange
On Thu, Aug 25, 2011 at 11:20:18AM -0600, Eric Blake wrote: On 08/25/2011 10:49 AM, Daniel P. Berrange wrote: From: Daniel P. Berrangeberra...@redhat.com The QEMU 'sendkey' command expects keys to be encoded in the same way as the RFB extended keycode set. Specfically it wants extended

Re: [libvirt] [PATCH 1/2] Fix keymap used to talk with QEMU

2011-08-26 Thread Eric Blake
On 08/26/2011 04:41 AM, Daniel P. Berrange wrote: +extern int (*codeOffsetVerify(void)) [verify_true (ARRAY_CARDINALITY(codeOffset) == VIR_KEYCODE_SET_LAST)]; \ Why the trailing backslash? Also, open-coding this verify is dangerous; gcc warnings have changed over time, rendering certain

[libvirt] [PATCH 1/2] Fix keymap used to talk with QEMU

2011-08-25 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The QEMU 'sendkey' command expects keys to be encoded in the same way as the RFB extended keycode set. Specfically it wants extended keys to have the high bit of the first byte set, while the Linux XT KBD driver codeset uses the low bit of the second

Re: [libvirt] [PATCH 1/2] Fix keymap used to talk with QEMU

2011-08-25 Thread Eric Blake
On 08/25/2011 10:49 AM, Daniel P. Berrange wrote: From: Daniel P. Berrangeberra...@redhat.com The QEMU 'sendkey' command expects keys to be encoded in the same way as the RFB extended keycode set. Specfically it wants extended s/Specfically/Specifically/ keys to have the high bit of the