All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Haxby <john.haxby@oracle.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 1 of 3] Fix keymap handling for vnc console
Date: Thu, 08 Jan 2009 20:46:46 +0000	[thread overview]
Message-ID: <49666636.30801@oracle.com> (raw)
In-Reply-To: <496661C6.3010507@codemonkey.ws>

Anthony Liguori wrote:
> John Haxby wrote:
>> Fix keymap handling for international keyboards
>>
>> Signed-off-by: John Haxby <john.haxby@oracle.com>
>>
[snip]
>
> Doing an in place sort of a literal array is probably not a great 
> idea.   Why does the array need sorting?  The indenting is really 
> screwed up here.
>
The size of the array is dramatically larger than it used to be -- over 
1000 entries -- so a linear search over about 200 keysyms is, I thought, 
a little excessive for linear search and would take an appreciable time 
at start up.  It also seems to me that more keysyms might need to be 
added in future: the choice was a one-off sort in the vnc_keysym.h 
definition which is prone to future editing errors or the one-off static 
sort in the code.  I tossed the arguments back and forth with my stuffed 
penguin and came down in favour of sorting the array: it's a technique 
I've used before when I wanted robust code at the expense of a little 
initialisation overhead.  Why do you think it's not a good idea?  I'll 
happily revisit the notion.

I have no idea why the indenting is screwed up -- it wasn't.   I think 
the Christmas Elves must've got at it.

Read and understood the remainder of the comments.   I'll re-submit the 
patches tomorrow -- thanks for looking.

jch

  reply	other threads:[~2009-01-08 20:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-16 15:32 [Qemu-devel] [PATCH 0 of 3] Fix keymap handling for vnc console John Haxby
2008-12-16 15:46 ` [Qemu-devel] [PATCH 1 " John Haxby
2009-01-08 20:27   ` Anthony Liguori
2009-01-08 20:46     ` John Haxby [this message]
2009-01-08 21:06       ` Anthony Liguori
2008-12-16 15:48 ` [Qemu-devel] [PATCH 2 " John Haxby
2008-12-16 15:49 ` [Qemu-devel] [PATCH 3 " John Haxby
2009-01-07 15:12 ` [Qemu-devel] [PATCH 0 " John Haxby
2009-01-08 20:17   ` Anthony Liguori

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=49666636.30801@oracle.com \
    --to=john.haxby@oracle.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.