Slowness (search opens every email file?)

Austin Clements amdragon at MIT.EDU
Tue Jul 12 19:22:47 PDT 2011


Quoth Istvan Marko on Jul 12 at  6:55 pm:
> Austin Clements <amdragon-3s7WtUTddSA at public.gmane.org> writes:
> 
> > Istvan, did you make any progress on this patch since the last
> > version?  I seem to recall it just needed general cleanup (code style
> > and such) and a better answer for backwards compatibility (the
> > unfortunate " " thing).
> 
> I have been using the version that encodes empty headers to " " but
> another way to handle this is to simply not set a VALUE for empty
> headers and then fall back to the original parsing method for these
> messages. Emails without from/subject/message-id headers are not very
> common so perhaps this is a good compromise.
> 
> Below is the patch without the " " hack.

Ah, clever.  I was going to suggest adding another value to indicate
the presence or absence of these Xapian values, but I like your
solution better.  The only downside I can think of is that it might
not extend to other headers if we store more header values in the
database in the future.

I'd say this patch looks good other than coding style
- Tab indentation
- /* */ comments, starting with a capital letter
- Space between function name and open paren
- Space after comma in argument lists
- Spaces around assignment operator


More information about the notmuch mailing list