<<< Date Index >>>     <<< Thread Index >>>

Re: keyboard handling (specifically mutt_getch)



On Tue, Dec 16, 2003 at 01:38:13AM -0500, Allister MacLeod wrote:

> I'm trying to figure out the normal flow of the km_dokey() function in
> mutt, and was curious about the line (around 390 of keymap.c):
> 
>     /* do we have an op already? */
>     if (tmp.op)
>     {
>     ...
> 
> As far as I can tell, tmp is only ever set by assignment from the
> mutt_getch() function.  Upon reading that function, it looks like
> maybe the .op field of the return value is only ever set when there is
> an error (and then its value is OP_NULL).  I'm not sure, though.  Can
> anyone tell me whether there are other cases where tmp.op would be
> nonzero?

Well, I'm affraid to say anything here, since I'll probably be wrong,
and you-know-who's gonna be gunnin' for my next wrong statement ;-P
(I've never even looked at this part of the code before.)  However,
what I can reliably say is that (a) that if is in a loop, (b) there are
multiple levels of recursion involved here, and (c) my head hurts just
looking at it.

HTH (though I doubt it will),
 - Dave

-- 
Uncle Cosmo, why do they call this a word processor?
It's simple, Skyler.  You've seen what food processors do to food, right?

Please visit this link:
http://rotter.net/israel

Attachment: pgpDHa1Sg7Gby.pgp
Description: PGP signature