grosjo / fts-xapian

Dovecot FTS plugin based on Xapian
GNU Lesser General Public License v2.1
97 stars 21 forks source link

Error: FTS Xapian: Unknown header 'message-id' #54

Closed heytings closed 4 years ago

heytings commented 4 years ago

From time to time I get a series of "Error: FTS Xapian: Unknown header 'message-id'" messages in dovecot.log. This error comes from XQuerySet::add(icu::UnicodeString h, icu::UnicodeString t, bool is_neg), because hdrs_emails[] contains "messageid" but not "message-id" (with a hyphen). Sometimes these messages appear in the middle of the night, so I guess that these messages are the result of a request sent by an MUA.

grosjo commented 4 years ago

The "-" is cleaned up from headers on line 379

        std::string f2;
        while(i<j)
        {
                if((field[i]>' ') && (field[i]!='"') && (field[i]!='\'') && (field[i]!='-'))
                {
                        f2+=tolower(field[i]);
                }
                i++;
        }
        ctx->tbi_field=i_strdup(f2.c_str());

Are you using hte latest release or git ?

heytings commented 4 years ago

Whoops, indeed not, I was using the version from @trentbuck (dated end of May), and did not include your latest fixes. Sorry for the noise. Issue closed :-)

trentbuck commented 4 years ago

Gregory Heytings wrote:

Whoops, indeed not, I was using the version from @trentbuck (dated end of May), and did not include your latest fixes. Sorry for the noise. Issue closed :-)

For the record, I just bumped & pushed my Debian integration stuff. Turns out I forgot to push it earlier; sorry.