NIIBE Yutaka
gniib****@fsij*****
2005年 10月 15日 (土) 15:20:55 JST
8 つめ。 Bug fix です。 mkdepgraph.c, mkdic.c では、wtype 関連の routine が使われますが、 イニシャライズされないままで、anthy_wt_all, anthy_wt_none が使われてま す。 * src-diclib/dic_main.h (anthy_init_wtypes): Removed declaration. * include/wtype.h (anthy_init_wtypes): ... but declared here. * mkanthydic/mkdic.c (main): Call anthy_init_wtypes. * depgraph/mkdepgraph.c (main): Likewise. diff --git a/depgraph/mkdepgraph.c b/depgraph/mkdepgraph.c --- a/depgraph/mkdepgraph.c +++ b/depgraph/mkdepgraph.c @@ -490,6 +490,7 @@ main(int argc, char* argv[]) anthy_conf_override("CONFFILE", "../anthy-conf"); anthy_conf_override("ANTHYDIR", SRCDIR "/../depgraph/"); + anthy_init_wtypes(); anthy_do_conf_init(); init_depword_tab(); init_word_seq_tab(); diff --git a/include/wtype.h b/include/wtype.h --- a/include/wtype.h +++ b/include/wtype.h @@ -220,6 +220,8 @@ void anthy_wtype_set_cos(wtype_t *w, int void anthy_wtype_set_scos(wtype_t *w, int scos); void anthy_wtype_set_dep(wtype_t *w, int isDep); +void anthy_init_wtypes(void); + extern wtype_t anthy_wt_all;/* すべてにマッチする自立語 */ extern wtype_t anthy_wt_none;/* 品詞無しPOS_INVAL */ diff --git a/mkanthydic/mkdic.c b/mkanthydic/mkdic.c --- a/mkanthydic/mkdic.c +++ b/mkanthydic/mkdic.c @@ -1158,6 +1158,7 @@ main(int argc, char **argv) char *script_fn = NULL; int help_mode = 0; + anthy_init_wtypes(); init_libs(); init_mds(&mds); diff --git a/src-diclib/dic_main.h b/src-diclib/dic_main.h --- a/src-diclib/dic_main.h +++ b/src-diclib/dic_main.h @@ -70,11 +70,6 @@ int anthy_file_dic_check_word_relation(s int from, int to); -/* wtype.c */ -void anthy_init_wtypes(void); - - - /* xchar.c */ void anthy_init_xchar_tab(void);