[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Patch to gperf 2.7.2 for case-independent keyword matching
From: |
Bruce Lilly |
Subject: |
Re: Patch to gperf 2.7.2 for case-independent keyword matching |
Date: |
Fri, 15 Feb 2002 01:48:49 -0500 |
Bruce Lilly wrote:
>
> In several important situations, keywords must be matched
> independent of case (email header field names, domain names,
> etc.).
>
> The attached patch to gperf 2.7.2 provides the option to
> generate output which does case-independent matching and
> documents that option.
>
> Best regards,
> Bruce Lilly
There was a small bug in the patch; apply the attached patch
after the first one.
*** src/key-list.cc.ng Fri Feb 15 01:31:21 2002
--- src/key-list.cc Fri Feb 15 01:32:30 2002
***************
*** 1110,1117 ****
if (count > 0)
printf (",");
if (!(count % max_column)) {
! if (isalnum(count) && isalnum(count+1-max_column))
! printf ("\t/* %c - %c */", count+1-max_column, count);
printf ("\n ");
}
printf ("%*d", field_width,
--- 1110,1117 ----
if (count > 0)
printf (",");
if (!(count % max_column)) {
! if (count && isalnum(count-1) && isalnum(count-max_column))
! printf ("\t/* %c - %c */", count-max_column, count-1);
printf ("\n ");
}
printf ("%*d", field_width,