野首です。 Debianパッケージの方で指摘を受けましたが、last-record2_default.utf8の 末尾に改行コードがないと無限ループになります。 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=777689
原因はEOFに達してもread_1_tokenが常にeolを0にするため、read_add_rowが 無限にread_1_tokenを呼び出すことになるからです。 以下はその修正差分になります。 diff --git a/ChangeLog b/ChangeLog index 3ecd1d0..b8228c5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2015-03-10 NOKUBI Takatsugu <[email protected]> + + * src-worddic/record.c (read_1_token): + check EOF without last return code to prevent infinite loop. + https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=777689 + 2009-02-09 AWASHIRO Ikuya <[email protected]> * configure.ac: bump to 9100h. diff --git a/src-worddic/record.c b/src-worddic/record.c index 66e85f3..5568a82 100644 --- a/src-worddic/record.c +++ b/src-worddic/record.c @@ -1043,7 +1043,7 @@ out: if (s) { s[len] = '\0'; } - *eol = (c == '\n'); + *eol = (c == '\n' || c == EOF); return s; } _______________________________________________ Anthy-dev mailing list [email protected] http://lists.sourceforge.jp/mailman/listinfo/anthy-dev
