--- FreeWnn-1.1.1-a022.bak/Wnn/include/jllib.h 2008-10-26 19:27:53.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/include/jllib.h 2013-08-07 04:36:57.146380820 +0900 @@ -253,8 +253,8 @@ /* extern function defines */ /* Note: FRWNN_PARAMS is defined in jslib.h . */ -extern struct wnn_buf *jl_open_lang FRWNN_PARAMS((char *env_n, char *server_n, char *lang, char *wnnrc_n, int (*error_handler) (), int (*message_handler) (), int timeout)); -extern struct wnn_env *jl_connect_lang FRWNN_PARAMS((register char *env_n, register char *server_n, register char *lang, register char *wnnrc_n, int (*error_handler) (), int (*message_handler) (), int timeout)); +extern struct wnn_buf *jl_open_lang FRWNN_PARAMS((const char *, const char *, const char *, const char *, int (*) (const char *), int (*) (const char *), int)); +extern struct wnn_env *jl_connect_lang FRWNN_PARAMS((register const char *, register const char *, register const char *, register const char *, int (*) (const char *), int (*) (const char *), int timeout)); extern struct wnn_env *jl_env_get FRWNN_PARAMS((register struct wnn_buf *buf)); extern struct wnn_jdata *jl_word_info_e FRWNN_PARAMS((register struct wnn_env *env, int dic_no, int entry)); extern w_char *jl_hinsi_name_e FRWNN_PARAMS((register struct wnn_env *env, register int no)); @@ -284,8 +284,8 @@ extern int jl_param_get_e FRWNN_PARAMS((struct wnn_env *env, struct wnn_param *para)); extern int jl_param_set_e FRWNN_PARAMS((register struct wnn_env *env, struct wnn_param *para)); extern int jl_ren_conv FRWNN_PARAMS((register struct wnn_buf *buf, register w_char *yomi, int bun_no, int bun_no2, int use_maep)); -extern int jl_set_env_wnnrc FRWNN_PARAMS((register struct wnn_env *env, char *wnnrc_n, int (*error_handler) (), int (*message_handler) () )); -extern int jl_set_env_wnnrc1 FRWNN_PARAMS((register struct wnn_env *env, char *wnnrc_n, int (*error_handler) (), int (*message_handler) (), int level)); +extern int jl_set_env_wnnrc FRWNN_PARAMS((register struct wnn_env *, const char *, int (*) (const char *), int (*) (const char *))); +extern int jl_set_env_wnnrc1 FRWNN_PARAMS((register struct wnn_env *, const char *, int (*) (const char *), int (*) (const char *), int)); extern int jl_set_jikouho FRWNN_PARAMS((register struct wnn_buf *buf, register int offset)); extern int jl_set_jikouho_dai FRWNN_PARAMS((register struct wnn_buf *buf, int offset)); extern int jl_tan_conv FRWNN_PARAMS((register struct wnn_buf *buf, w_char *yomi, register int bun_no, register int bun_no2, int use_maep, int ich_shop)); diff -ur FreeWnn-1.1.1-a022.bak/Wnn/include/jslib.h FreeWnn-1.1.1-a022/Wnn/include/jslib.h --- FreeWnn-1.1.1-a022.bak/Wnn/include/jslib.h 2013-08-07 06:07:20.597599679 +0900 +++ FreeWnn-1.1.1-a022/Wnn/include/jslib.h 2013-08-07 04:59:14.523936167 +0900 @@ -137,6 +137,18 @@ /* js_who */ #define WNN_MAX_ENV_OF_A_CLIENT 32 +#ifndef FRWNN_PARAMS +/* + * I currently think ANSI-C is not sufficient on building your clients + * linked with libwnn. (aonoto) + */ +#if __STDC__ /* Sufficient? */ +#define FRWNN_PARAMS(paramlist) paramlist +#else +#define FRWNN_PARAMS(paramlist) () +#endif +#endif + struct wnn_jwho { int sd; /* jserver 内のソケットディスクリプタ */ @@ -403,17 +415,6 @@ #define js_open(server, timeout) js_open_lang((server), "ja", (timeout)) #define js_connect(server,env_name) js_connect_lang((server), (env_name), "ja") -#ifndef FRWNN_PARAMS -/* - * I currently think ANSI-C is not sufficiant on building your clients - * linked with libwnn. (aonoto) - */ -#if __STDC__ /* Sufficient? */ -#define FRWNN_PARAMS(paramlist) paramlist -#else -#define FRWNN_PARAMS(paramlist) () -#endif -#endif extern WNN_JSERVER_ID *js_open_lang FRWNN_PARAMS((register char *server, register char *lang, register int timeout)); extern int js_close FRWNN_PARAMS((WNN_JSERVER_ID *server)); --- FreeWnn-1.1.1-a022.bak/Wnn/include/wnn_string.h 2005-04-11 00:26:37.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/include/wnn_string.h 2013-08-07 04:46:51.470301270 +0900 @@ -33,26 +33,28 @@ #ifndef WNN_STRING_H #define WNN_STRING_H -extern int wnn_sStrcpy (); -extern int wnn_Sstrcpy (); -extern void wnn_Sreverse (); -extern char *wnn_Stos (); -extern char *wnn_sStrncpy (); -extern w_char *wnn_Strcat (); -extern w_char *wnn_Strncat (); -extern int wnn_Strcmp (); -extern int wnn_Substr (); -extern int wnn_Strncmp (); -extern w_char *wnn_Strncpy (); -extern int wnn_Strlen (); -extern w_char *wnn_Strcpy (); -extern void wnn_delete_w_ss2 (); -extern int wnn_byte_count (); +#include "jslib.h" + +extern int wnn_sStrcpy FRWNN_PARAMS((register char*, register w_char*)); +extern int wnn_Sstrcpy FRWNN_PARAMS((w_char*,unsigned char*)); +extern void wnn_Sreverse FRWNN_PARAMS((w_char*,w_char*)); +extern char *wnn_Stos FRWNN_PARAMS((w_char*)); +extern char *wnn_sStrncpy FRWNN_PARAMS((register char*,register w_char*,int)); +extern w_char *wnn_Strcat FRWNN_PARAMS((register w_char*,register w_char*)); +extern w_char *wnn_Strncat FRWNN_PARAMS((register w_char*,register w_char*,int)); +extern int wnn_Strcmp FRWNN_PARAMS((register w_char*,register w_char*)); +extern int wnn_Substr FRWNN_PARAMS((register w_char*,register w_char*)); +extern int wnn_Strncmp FRWNN_PARAMS((register w_char*,register w_char*,int)); +extern w_char *wnn_Strncpy FRWNN_PARAMS((register w_char*,register w_char*,int)); +extern int wnn_Strlen FRWNN_PARAMS((register w_char*)); +extern w_char *wnn_Strcpy FRWNN_PARAMS((register w_char*,register w_char*)); +extern void wnn_delete_w_ss2 FRWNN_PARAMS((register w_char*,int)); +extern int wnn_byte_count FRWNN_PARAMS((register int)); #ifndef JS -extern int check_pwd (); +extern int check_pwd FRWNN_PARAMS((char*,char*)); #endif #ifdef CHINESE -extern int wnn_Sstrcat (); +extern int wnn_Sstrcat FRWNN_PARAMS((w_char*,unsigned char*)); #endif #endif /* WNN_STRING_H */ --- FreeWnn-1.1.1-a022.bak/Wnn/jlib/jl.c 2013-08-07 06:09:46.107457087 +0900 +++ FreeWnn-1.1.1-a022/Wnn/jlib/jl.c 2013-08-07 04:17:54.549210149 +0900 @@ -132,7 +132,7 @@ static void add_down_bnst (); static int alloc_heap (); -static int call_error_handler (); +static int call_error_handler FRWNN_PARAMS((int (*) (const char *), const char *)); static int change_ascii_to_int (); static int create_file (); static int dai_end (); --- FreeWnn-1.1.1-a022.bak/Wnn/jserver/error.c 2013-08-07 06:10:21.510265098 +0900 +++ FreeWnn-1.1.1-a022/Wnn/jserver/error.c 2003-06-08 12:09:51.000000000 +0900 @@ -82,7 +82,7 @@ void error_exit1 (x, y1, y2, y3, y4, y5) char *x; - long y1, y2, y3, y4, y5; + int y1, y2, y3, y4, y5; { /* Need care with buffer size */ char buf[512]; @@ -270,7 +270,7 @@ void out (x, y1, y2, y3, y4, y5, y6, y7, y8, y9, y10, y11, y12) char *x; - long y1, y2, y3, y4, y5, y6, y7, y8, y9, y10, y11, y12; + int y1, y2, y3, y4, y5, y6, y7, y8, y9, y10, y11, y12; { if (!noisy) return; --- FreeWnn-1.1.1-a022.bak/Wnn/jutil/atod.c 2004-08-12 18:03:19.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/jutil/atod.c 2013-08-07 00:06:48.611412840 +0900 @@ -70,19 +70,60 @@ #include "wnn_string.h" #include "wnn_os.h" -extern int wnn_loadhinsi (), init_heap (), little_endian (), Sorted (), asshuku (), revdic (); -extern void ujis_header (), read_ujis (), reverse_yomi (), create_rev_dict (), -uniq_je (), sort_if_not_sorted (), output_header (), udytoS (), output_ri (), exit1 (), new_pwd (), rev_short_fun (), rev_w_char (); +extern int wnn_loadhinsi FRWNN_PARAMS((unsigned char*)), + init_heap FRWNN_PARAMS((int,int,int,int,FILE*)), + little_endian FRWNN_PARAMS(()), + Sorted FRWNN_PARAMS((register char*,register int,int,int (*sort_fun)(char*,char*))), + asshuku FRWNN_PARAMS((int)), + revdic FRWNN_PARAMS((struct JT *,int)); +#ifdef CHINESE +extern void ujis_header FRWNN_PARAMS((int*)); +#else +extern void ujis_header FRWNN_PARAMS((void)); +#endif +extern void read_ujis FRWNN_PARAMS((int,int,int)), + reverse_yomi FRWNN_PARAMS((void)), + create_rev_dict FRWNN_PARAMS((void)), + uniq_je FRWNN_PARAMS((int(*func)(char*,char*))), + sort_if_not_sorted FRWNN_PARAMS((void)), + output_header FRWNN_PARAMS((FILE*,struct JT*,struct wnn_file_head*)), + udytoS FRWNN_PARAMS((w_char*,int,char*,struct uind1*)), + output_ri FRWNN_PARAMS((FILE*)), + exit1 FRWNN_PARAMS((void)), + new_pwd FRWNN_PARAMS((char*,char*)), + rev_short_fun FRWNN_PARAMS((w_char*)), + rev_w_char FRWNN_PARAMS((w_char*,int)); + + extern #ifdef BDIC_WRITE_CHECK int #else void #endif - put_n_EU_str (); -static void ujistoud (), output_dic_index (), usage (), sdic_sort (), -ujistosd (), not_enough_area (), get_pwd (), output_hindo (), output_hinsi (), output_kanji (), rev_dic_data (), set_pter1 (), output_comment (), output_hinsi_list (); -void upd_kanjicount (), output_dic_data (); + put_n_EU_str FRWNN_PARAMS((FILE*,w_char*,int)); + +extern int sort_func_sdic FRWNN_PARAMS((char*,char*)); +extern int sort_func_je FRWNN_PARAMS((char*,char*)); +extern char *get_cswidth_name FRWNN_PARAMS((register char*)); +extern void set_cswidth FRWNN_PARAMS((register unsigned int)); + +static void ujistoud FRWNN_PARAMS((void)), + output_dic_index FRWNN_PARAMS((void)), + usage FRWNN_PARAMS((void)), + sdic_sort FRWNN_PARAMS((void)), + ujistosd FRWNN_PARAMS((int,int)), + not_enough_area FRWNN_PARAMS((void)), + get_pwd FRWNN_PARAMS((char*,char*)), + output_hindo FRWNN_PARAMS((FILE*)), + output_hinsi FRWNN_PARAMS((FILE*)), + output_kanji FRWNN_PARAMS((FILE*)), + rev_dic_data FRWNN_PARAMS((void)), + set_pter1 FRWNN_PARAMS((void)), + output_comment FRWNN_PARAMS((FILE*)), + output_hinsi_list FRWNN_PARAMS((FILE*)); +void upd_kanjicount FRWNN_PARAMS((int)), + output_dic_data FRWNN_PARAMS((void)); /* Switcher variable between UD and SD */ @@ -115,8 +156,7 @@ int tnum = 0; struct uind2 *uhopter; -char *hinsi_file_name = NULL; - +unsigned char *hinsi_file_name = NULL; void init (int argc, char **argv) @@ -221,16 +261,12 @@ } } -extern int sort_func_sdic (); -extern int sort_func_je (); FILE *ofpter; int main (int argc, char** argv) { char *cswidth_name; - extern char *get_cswidth_name (); - extern void set_cswidth (); com_name = argv[0]; init (argc, argv); @@ -442,7 +478,7 @@ { if (which_dict == WNN_UD_DICT) { - fprintf (stderr, " tnum = %d\n ind2= %d\n kanji = %d\n", tnum, (char *) uhopter - (char *) hostart, kanjicount); + fprintf (stderr, " tnum = %d\n ind2= %d\n kanji = %d\n", tnum, (int)((char *) uhopter - (char *) hostart), kanjicount); jt.maxtable = tnum; jt.maxhontai = (char *) uhopter - (char *) hostart; jt.maxri2 = jt.maxri1[D_YOMI] = jt.maxri1[D_KANJI] = 0; @@ -470,7 +506,7 @@ } else { - fprintf (stderr, "node_count = %d ind= %d\n kanji = %d\n", node_count, (char *) hopter - (char *) hostart, kanjicount); + fprintf (stderr, "node_count = %d ind= %d\n kanji = %d\n", node_count, (int)((char *) hopter - (char *) hostart), kanjicount); jt.maxtable = 0; jt.maxhontai = (char *) hopter - (char *) hostart; jt.maxri2 = jt.maxri1[D_YOMI] = jt.maxri1[D_KANJI] = 0; --- FreeWnn-1.1.1-a022.bak/Wnn/romkan/rk_bltinfn.c 2005-04-11 00:26:38.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/romkan/rk_bltinfn.c 2013-08-06 22:57:34.504818981 +0900 @@ -52,6 +52,7 @@ #include "commonhd.h" #include "wnn_config.h" #include "rk_header.h" +#include "jslib.h" /* 半角文字のコードのdefine */ #define HKCHOU (HNKAK1 * 0x100 + 0xB0) /* ー */ @@ -73,6 +74,10 @@ #define TOUTEN (0xA1A2) /* 、 */ #define NKPOTU (0xA1A6) /* ・ */ +/* This is bad code . It should be declared in the header . + * But where should it be declared ? */ +extern letter vtol FRWNN_PARAMS((letter)); + static char _lang[6]; void @@ -371,7 +376,7 @@ to_digit (in, base, outp) letter in, base, **outp; { - letter c, vtol (); + letter c; if (c = in, c /= base) to_digit (c, base, outp); diff -ur FreeWnn-1.1.1-a022.bak/Wnn/romkan/rk_fundecl.h FreeWnn-1.1.1-a022/Wnn/romkan/rk_fundecl.h --- FreeWnn-1.1.1-a022.bak/Wnn/romkan/rk_fundecl.h 2005-04-11 00:26:38.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/romkan/rk_fundecl.h 2013-08-06 23:04:20.136621426 +0900 @@ -39,12 +39,21 @@ ***********************************************************************/ /* Version 3.0 */ -extern letter *ltrncpy (); -extern int ltrcmp (), ltrncmp (); -extern int romkan_init (), romkan_init2 (), romkan_init3 (); -extern letter romkan_getc (), *romkan_henkan (), romkan_next (); -extern letter romkan_ungetc (), romkan_unnext (); -extern void romkan_clear (); -extern char *romkan_dispmode (); +#include "jslib.h" + +extern letter *ltrncpy FRWNN_PARAMS((letter*,letter*,int)); +extern int ltrcmp FRWNN_PARAMS((letter*,letter*)), + ltrncmp FRWNN_PARAMS((letter*,letter*,int)); + +extern int romkan_init FRWNN_PARAMS((char*,letter,char,letter(*keyinfn)(),int(*bytcntfn)())), + romkan_init2 FRWNN_PARAMS((char*,letter,char,letter(*keyinfn)(),int(*bytcntfn)(),char,char,char)), + romkan_init3 FRWNN_PARAMS((char*,letter,letter,letter,letter(*keyinfn)(),int(*bytcntfn)(),int(*kbytcntfn)(),char,int)); +extern letter romkan_getc FRWNN_PARAMS((void)), + *romkan_henkan FRWNN_PARAMS((letter)), + romkan_next FRWNN_PARAMS((void)); +extern letter romkan_ungetc FRWNN_PARAMS((letter)), + romkan_unnext FRWNN_PARAMS((letter)); +extern void romkan_clear FRWNN_PARAMS((void)); +extern char *romkan_dispmode FRWNN_PARAMS((void)); extern char rk_errstat; /* これは関数ではなく変数 */ diff -ur FreeWnn-1.1.1-a022.bak/Wnn/romkan/rk_main.c FreeWnn-1.1.1-a022/Wnn/romkan/rk_main.c --- FreeWnn-1.1.1-a022.bak/Wnn/romkan/rk_main.c 2005-04-11 00:26:38.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/romkan/rk_main.c 2013-08-06 23:19:20.204768004 +0900 @@ -42,6 +42,7 @@ #include "rk_header.h" #include "rk_extvars.h" #include "rk_fundecl.h" +#include "jslib.h" struct matchpair /* 現在マッチされている変数の番号と、マッチした文字の 組を保持。 */ @@ -91,23 +92,48 @@ letter saishu_out[OUTSIZ]; letter delchr, delchr2 = EOLTTR, nisedl; /* DELのキャラクタは二個まで持てる */ -modetyp chgmod (), incmod (), decmod (); - +modetyp chgmod FRWNN_PARAMS((int,modetyp)), + incmod FRWNN_PARAMS((int,modetyp)), + decmod FRWNN_PARAMS((int,modetyp)); /* letterを返す関数の定義及び宣言(一部にはcharのものも混じっている) */ -static letter mchedsrc (); -letter romkan_next (), romkan_unnext (); -letter romkan_getc (), romkan_ungetc (), *romkan_henkan (); -letter to_zenalpha (), to_zenhira (), to_zenkata (); +static letter mchedsrc FRWNN_PARAMS((int)); +letter romkan_next FRWNN_PARAMS((void)), + romkan_unnext FRWNN_PARAMS((letter)); +letter romkan_getc FRWNN_PARAMS((void)), + romkan_ungetc FRWNN_PARAMS((letter)), + *romkan_henkan FRWNN_PARAMS((letter)); +letter to_zenalpha FRWNN_PARAMS((letter)), + to_zenhira FRWNN_PARAMS((letter)), + to_zenkata FRWNN_PARAMS((letter)); /* to_zenhira;kata は濁点を持つ文字を一まとめにしない。 */ -void BUGreport (); -static void maeato_henkan (), add_at_eof (), rk_delete (), set_rubout (), mchevl (), codeout_chg (), ltrevlcpy (); -int match (); -static int p_eq (), hen_ikisrc (), henkan_ok (), rk_rst (), head_bytecount (); -extern void readdata (), romkan_reset (), hank_setup (), to_hankata (), to_digit (), dakuadd (), handakuadd (), allchgmod (); -extern int ltov (); +void BUGreport FRWNN_PARAMS((int)); +static void maeato_henkan FRWNN_PARAMS((letter,letter*,int*)), + add_at_eof FRWNN_PARAMS((void)), + rk_delete FRWNN_PARAMS((letter)), + set_rubout FRWNN_PARAMS((letter*,int,letter)), + mchevl FRWNN_PARAMS((letter**,letter*)), + codeout_chg FRWNN_PARAMS((void)), + ltrevlcpy FRWNN_PARAMS((letter*,letter*)); +int match FRWNN_PARAMS((void)); +static int p_eq FRWNN_PARAMS((register letter**,register letter**)), + hen_ikisrc FRWNN_PARAMS((int,letter)), + henkan_ok FRWNN_PARAMS((void)), + rk_rst FRWNN_PARAMS((void)), + head_bytecount FRWNN_PARAMS((uns_chr*)); +extern void readdata FRWNN_PARAMS((letter*,struct dat*,letter**,char*)), + romkan_reset FRWNN_PARAMS((void)), + hank_setup FRWNN_PARAMS((void)), + to_hankata FRWNN_PARAMS((letter,letter**)), + to_digit FRWNN_PARAMS((letter,letter,letter**)), + dakuadd FRWNN_PARAMS((letter,letter**)), + handakuadd FRWNN_PARAMS((letter,letter**)), + allchgmod FRWNN_PARAMS((modetyp)); +extern int ltov FRWNN_PARAMS((letter)); +int romkan_init2 FRWNN_PARAMS((char*,letter,char,letter(*keyinfn)(),int(*bytcntfn)(),char,char,char)); +int romkan_init3 FRWNN_PARAMS((char*,letter,letter,letter,letter(*keyinfn)(),int(*bytcntfn)(),int(*kbytcntfn)(),char,int)); static letter * ltrcpy (lp1, lp2) --- FreeWnn-1.1.1-a022.bak/Wnn/romkan/rk_modread.c 2005-04-11 00:26:38.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/romkan/rk_modread.c 2013-08-06 23:35:25.974413286 +0900 @@ -60,20 +60,42 @@ /* マクロLIBDIRの定義(のためだけ)。コンパイル時は、ヘッダファイルの サーチパスに、Wnnのインクルードファイルのありかを設定しておくこと。 */ #endif +#include "jslib.h" #define Terminator 0 /* intの列(naibu[])の終止コード */ -extern char *chrcat (), *strend (), *ename (); +extern char *chrcat FRWNN_PARAMS((char*,char)), + *strend FRWNN_PARAMS((char*)), + *ename FRWNN_PARAMS((char*)); extern void romkan_clear (); char *modhyopath; -static void cond_evl (), mystrcpy (), rd_bcksla (), rd_ctrl (), hyouse (), look_choose (); +static void cond_evl FRWNN_PARAMS((char*)), + mystrcpy FRWNN_PARAMS((char*,char*)), + rd_bcksla FRWNN_PARAMS((register FILE*,char**)), + rd_ctrl FRWNN_PARAMS((register FILE*,char**)), + hyouse FRWNN_PARAMS((int)), + look_choose FRWNN_PARAMS((int**,int)); void choosehyo (); -static int mystrcmp (), read1tm (), mod_evl (), fnmsrc_tourk (), dspnamsrc_tourk (), -scan1tm (), modsrc_tourk (), chk_get_int (), pathsrc_tourk (), modnamchk (), ctov (), look_cond (), evlcond (), chkchar_getc (); -static char codeeval (); -extern void ERRMOD (), ERMOPN (), BUGreport (); -extern int filnamchk (); +static int mystrcmp FRWNN_PARAMS((char*,char*)), + read1tm FRWNN_PARAMS((char**,int)), + mod_evl FRWNN_PARAMS((char*)), + fnmsrc_tourk FRWNN_PARAMS((char*)), + dspnamsrc_tourk FRWNN_PARAMS((char*)), + scan1tm FRWNN_PARAMS((char**,char*,int)), + modsrc_tourk FRWNN_PARAMS((char*,int)), + chk_get_int FRWNN_PARAMS((char*,unsigned int*,modetyp)), + pathsrc_tourk FRWNN_PARAMS((char*)), + modnamchk FRWNN_PARAMS((char*)), + ctov FRWNN_PARAMS((char)), + look_cond FRWNN_PARAMS((int**,int)), + evlcond FRWNN_PARAMS((int**)), + chkchar_getc FRWNN_PARAMS((FILE*)); +static char codeeval FRWNN_PARAMS((register char**)); +extern void ERRMOD FRWNN_PARAMS((unsigned int)), + ERMOPN FRWNN_PARAMS((unsigned int)), + BUGreport FRWNN_PARAMS((int)); +extern int filnamchk FRWNN_PARAMS((char*)); struct kwdpair { @@ -122,6 +144,7 @@ return (i); ERRMOD (9); /*NOTREACHED*/ + return 0; } /** モード表の読み込み */ --- FreeWnn-1.1.1-a022.bak/Wnn/romkan/rk_read.c 2005-04-11 00:26:38.000000000 +0900 +++ FreeWnn-1.1.1-a022/Wnn/romkan/rk_read.c 2013-08-06 23:47:10.950793006 +0900 @@ -50,17 +50,48 @@ #include #include "rk_header.h" #include "rk_extvars.h" +#include "jslib.h" -letter onescan (), *rangekettei (); -char *ename (); +letter onescan FRWNN_PARAMS((letter**,letter*)), + *rangekettei FRWNN_PARAMS((int,letter*)); +char *ename FRWNN_PARAMS((char*)); -extern letter *ltrgrow (), *ltrend (), letterpick (), *ltr1cut (); -extern char *chrcat (), *strend (); +extern letter *ltrgrow FRWNN_PARAMS((letter*,letter*)), + *ltrend FRWNN_PARAMS((letter*)), + letterpick FRWNN_PARAMS((uns_chr**)), + *ltr1cut FRWNN_PARAMS((letter*)); +extern char *chrcat FRWNN_PARAMS((char*,char)), + *strend FRWNN_PARAMS((char*)); -static int termsscan (), evalandcpy (), eval1cpy (), partscan (), evlis (), atermscan (), serfun (), hensrc_tourk (), blankpass (), modsrcL (), chkL_get_int (); -static void ERRLIN (), ERHOPN (), readhyo (), ltr1tostr (), ERRHYO (), vchk (), rangeset (), de_bcksla (), listscan (), singleqscan (), doubleqscan (); -extern void BUGreport (), choosehyo (), readmode (); -extern int ltrcmp (), ltrstrcmp (), readfnm (), fixednamep (); +static int termsscan FRWNN_PARAMS((register letter**,letter*,int)), + evalandcpy FRWNN_PARAMS((register letter**,int)), + eval1cpy FRWNN_PARAMS((letter**,int,int)), + partscan FRWNN_PARAMS((register letter**,register letter*)), + evlis FRWNN_PARAMS((int,letter**,int)), + atermscan FRWNN_PARAMS((register letter**,register letter*,int)), + serfun FRWNN_PARAMS((register letter*)), + hensrc_tourk FRWNN_PARAMS((letter*,int)), + blankpass FRWNN_PARAMS((register letter**,int)), + modsrcL FRWNN_PARAMS((letter*)), + chkL_get_int FRWNN_PARAMS((letter*,modetyp*,modetyp)); +static void ERRLIN FRWNN_PARAMS((unsigned int)), + ERHOPN FRWNN_PARAMS((unsigned int)), + readhyo FRWNN_PARAMS((int)), + ltr1tostr FRWNN_PARAMS((letter,char**)), + ERRHYO FRWNN_PARAMS((unsigned int)), + vchk FRWNN_PARAMS((letter*)), + rangeset FRWNN_PARAMS((int,letter*)), + de_bcksla FRWNN_PARAMS((char*,char*)), + listscan FRWNN_PARAMS((register letter**,register letter*)), + singleqscan FRWNN_PARAMS((letter**,letter*)), + doubleqscan FRWNN_PARAMS((letter**,letter*)); +extern void BUGreport FRWNN_PARAMS((int)), + choosehyo FRWNN_PARAMS((void)), + readmode FRWNN_PARAMS((char*)); +extern int ltrcmp FRWNN_PARAMS((letter*,letter*)), + ltrstrcmp FRWNN_PARAMS((register letter*,register char*)), + readfnm FRWNN_PARAMS((int (*readchar_func) (void),int (*unreadc_func) (int),int (*readstr_func) (char**,int),char**,int*)), + fixednamep FRWNN_PARAMS((char*)); #define IHENSU (1 << 24) /* 内部表現の上位1バイトで、変数を表す */ #define IKANSU (2 << 24) /* 〃 関数を表す */ --- FreeWnn-1.1.1-a022.bak/Xwnmo/xwnmo/do_socket.c 2013-08-07 06:10:21.520265048 +0900 +++ FreeWnn-1.1.1-a022/Xwnmo/xwnmo/do_socket.c 2001-06-15 03:16:14.000000000 +0900 @@ -90,9 +90,9 @@ XIMCmblk *cblk; XIMCmblk *cur_cblk = NULL; -fd_set *all_socks; -fd_set *ready_socks; -static fd_set *dummy1_socks, *dummy2_socks; +int *all_socks; +int *ready_socks; +static int *dummy1_socks, *dummy2_socks; static int sel_width; static int nofile; @@ -114,14 +114,9 @@ static int rc = 0; #define BINTSIZE (sizeof(int)*8) -/* #define sock_set(array,pos) (array[pos/BINTSIZE] |= (1<<(pos%BINTSIZE))) #define sock_clr(array,pos) (array[pos/BINTSIZE] &= ~(1<<(pos%BINTSIZE))) -#define sock_tst(array,pos) (array[pos/BINTSIZE] & (1<<(pos%BINTSIZE))) -*/ -#define sock_set(array,pos) FD_SET(pos,array) -#define sock_clr(array,pos) FD_CLR(pos,array) -#define sock_tst(array,pos) FD_ISSET(pos,array) +#define sock_tst(array,pos) (array[pos/BINTSIZE] & (1<<(pos%BINTSIZE))) extern int read (), write ();