From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:46534) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFhsH-0000Sr-3J for qemu-devel@nongnu.org; Sun, 23 Sep 2012 04:49:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TFhsG-0002Wt-5w for qemu-devel@nongnu.org; Sun, 23 Sep 2012 04:49:13 -0400 Received: from mx1.redhat.com ([209.132.183.28]:54926) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFhsF-0002Wj-To for qemu-devel@nongnu.org; Sun, 23 Sep 2012 04:49:12 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q8N8nAvK030433 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 23 Sep 2012 04:49:11 -0400 Message-ID: <505ECD03.6000107@redhat.com> Date: Sun, 23 Sep 2012 10:49:07 +0200 From: Avi Kivity MIME-Version: 1.0 References: <1348239340-29021-1-git-send-email-lcapitulino@redhat.com> <1348239340-29021-3-git-send-email-lcapitulino@redhat.com> <505C965B.1050504@redhat.com> <20120921134234.5d836bc5@doriath.home> <20120921142634.2d4707c4@doriath.home> <505CAF7C.5040403@redhat.com> <505CAFD4.2000708@redhat.com> In-Reply-To: <505CAFD4.2000708@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 2/3] qmp: qmp_send_key(): accept key codes in hex List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: akong@redhat.com, qemu-devel@nongnu.org, Luiz Capitulino On 09/21/2012 09:20 PM, Eric Blake wrote: > On 09/21/2012 12:18 PM, Eric Blake wrote: > >> Any better ideas? > > > > Maybe s/hex/number/, as in: > > > > JSON: 'number':0x20 > > > > C code: keylist->value->number = number; > > > > that is, you are passing the value either as a keycode name, or as a number. > > Or even s/hex/int/ > > except that the C code would then have to use mangling (since the JSON > name would match a C keyword). > 'keycode'? -- I have a truly marvellous patch that fixes the bug which this signature is too narrow to contain.