changeset 12:1f16ab4b33e5

add prototypes for functions to jslib.h
author Yoshiki Yazawa <yaz@cc.rim.or.jp>
date Sun, 02 Mar 2008 19:07:21 +0900
parents aa17e2acfa01
children 778894f4449f
files Wnn/include/jslib.h Wnn/jlib/js.c
diffstat 2 files changed, 139 insertions(+), 297 deletions(-) [+]
line wrap: on
line diff
--- a/Wnn/include/jslib.h	Sun Mar 02 04:48:21 2008 +0900
+++ b/Wnn/include/jslib.h	Sun Mar 02 19:07:21 2008 +0900
@@ -399,70 +399,74 @@
 #define js_open(server, timeout)        js_open_lang(server, "ja_JP", timeout)
 #define js_connect(server,env_name)     js_connect_lang(server, env_name, "ja_JP")
 
-extern WNN_JSERVER_ID *js_open_lang ();
-extern int js_close ();
-extern WNN_JSERVER_ID *js_change_current_jserver ();
-extern struct wnn_env *js_connect_lang ();
-extern int js_disconnect ();
-extern int js_env_list ();
-extern int js_param_set ();
-extern int js_param_get ();
-extern char *js_get_lang ();
+/* prototypes */
+WNN_JSERVER_ID *js_open_lang (register char *server, register char *lang, register int timeout);
+int js_close (WNN_JSERVER_ID *server);
+struct wnn_env *js_connect_lang (WNN_JSERVER_ID *server, register char *env_name, char *lang);
+int js_disconnect (register struct wnn_env *env);
+
+int js_env_list (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret);
+int js_param_set(struct wnn_env *env, register struct wnn_param *para);
+int js_param_get(struct wnn_env *env, register struct wnn_param *para);
+char *js_get_lang(struct wnn_env *env);
 /**************************************/
-extern int js_access ();
-extern int js_dic_add ();
-extern int js_dic_delete ();
-extern int js_dic_file_create ();
-extern int js_dic_file_create_client ();
-extern int js_dic_info ();
-extern int js_dic_list ();
-extern int js_dic_list_all ();
-extern int js_dic_use ();
-extern int js_env_exist ();
-extern int js_env_sticky ();
-extern int js_env_un_sticky ();
-extern int js_file_comment_set ();
-extern int js_file_discard ();
-extern int js_file_info ();
-extern int js_file_list ();
-extern int js_file_list_all ();
-extern int js_file_loaded ();
-extern int js_file_loaded_local ();
-extern int js_file_password_set ();
-extern int js_file_read ();
-extern int js_file_receive ();
-extern int js_file_remove ();
-extern int js_file_remove_client ();
-extern int js_file_send ();
-extern int js_file_stat ();
-extern int js_file_write ();
-extern void js_flush ();
-extern int js_fuzokugo_get ();
-extern int js_fuzokugo_set ();
-extern int js_hindo_file_create ();
-extern int js_hindo_file_create_client ();
-extern int js_hindo_set ();
-extern int js_hinsi_dicts ();
-extern int js_hinsi_list ();
-extern int js_hinsi_name ();
-extern int js_hinsi_number ();
-extern int js_hinsi_table_set ();
-extern int js_isconnect ();
-extern int js_kanren ();
-extern int js_kantan_dai ();
-extern int js_kantan_sho ();
-extern int js_kanzen_dai ();
-extern int js_kanzen_sho ();
-extern int js_kill ();
-extern int js_mkdir ();
-extern int js_version ();
-extern int js_who ();
-extern int js_word_add ();
-extern int js_word_comment_set ();
-extern int js_word_delete ();
-extern int js_word_info ();
-extern int js_word_search ();
-extern int js_word_search_by_env ();
+int js_access(struct wnn_env *env, char *path, int amode);
+int js_dic_add(struct wnn_env *env, int fid, int hfid, int rev, int jnice, int rw, int hrw, char *pw1, char *pw2);
+int js_dic_delete(struct wnn_env *env, int dicno);
+int js_dic_file_create (struct wnn_env *env, char *fn, int type, w_char *comment, char *passwd, char *hpasswd);
+int js_dic_file_create_client (struct wnn_env *env, char *fn, int type, w_char *com, char *passwd, char *hpasswd);
+int js_dic_info (struct wnn_env *env, int dic_no, register WNN_DIC_INFO *ret);
+int js_dic_list(struct wnn_env *env, struct wnn_ret_buf *ret);
+int js_dic_list_all (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret);
+int js_dic_use(struct wnn_env *env, int dic_no, int flag);
+int js_env_exist (register WNN_JSERVER_ID *server, register char *env_name);
+int js_env_sticky(register struct wnn_env *env);
+int js_env_un_sticky(register struct wnn_env *env);
+int js_file_comment_set (struct wnn_env *env, int fid, w_char *comment);
+int js_file_discard(struct wnn_env *env, int fid);
+int js_file_info (struct wnn_env *env, int fid, register WNN_FILE_INFO_STRUCT *file);
+int js_file_list(struct wnn_env *env, struct wnn_ret_buf *ret);
+int js_file_list_all (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret);
+int js_file_loaded (WNN_JSERVER_ID *server, char *path);
+int js_file_loaded_local (WNN_JSERVER_ID *server, char *path);
+int js_file_password_set(struct wnn_env *env, int fid, int which, char *old, char *new);
+int js_file_read(struct wnn_env *env, char *fn);
+int js_file_receive(struct wnn_env *env, int fid, char *fn);
+int js_file_remove (WNN_JSERVER_ID *server, char *n, char *pwd);
+int js_file_remove_client (WNN_JSERVER_ID *server, char *n, char *pwd);
+int js_file_send(struct wnn_env *env, char *fn);
+int js_file_stat (struct wnn_env *env, char *path, WNN_FILE_STAT *s);
+int js_file_write(struct wnn_env *env, int fid, char *fn);
+int js_fuzokugo_get(struct wnn_env *env);
+int js_fuzokugo_set(struct wnn_env *env, int fid);
+void js_flush (struct wnn_env *env);
+int js_hindo_file_create (struct wnn_env *env, int fid, char *fn, w_char *comment, char *hpasswd);
+int js_hindo_file_create_client (struct wnn_env *env, int fid, char *fn, w_char *com, char *hpasswd);
+int js_hindo_set(struct wnn_env *env, int dic, int entry, int ima, int hindo);
+int js_hinsi_dicts(struct wnn_env *env, int no, struct wnn_ret_buf *rb);
+int js_hinsi_list (struct wnn_env *env, int dic_no, w_char *name, struct wnn_ret_buf *rb);
+int js_hinsi_name (WNN_JSERVER_ID *server, int no, struct wnn_ret_buf *rb);
+int js_hinsi_number (WNN_JSERVER_ID *server, w_char *name);
+int js_hinsi_table_set (struct wnn_env *env, int dic_no, w_char *hinsi_table);
+int js_isconnect (register struct wnn_env *env);
+int js_kanren (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, int vec2, struct wnn_ret_buf *rb);
+int js_kantan_dai (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb);
+int js_kantan_sho (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb);
+int js_kanzen_dai (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb);
+int js_kanzen_sho (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb);
+int js_kill (WNN_JSERVER_ID *server);
+int js_mkdir(struct wnn_env *env, char *path);
+int js_version (WNN_JSERVER_ID *server, int *serv, int *libv);
+int js_who (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret);
+int js_word_add (struct wnn_env *env, int dic_no, w_char *yomi, w_char *kanji, w_char *comment, int hinshi, int init_hindo);
+int js_word_comment_set (struct wnn_env *env, int dic_no, int entry, w_char *comment);
+int js_word_delete(struct wnn_env *env, int dic_no, int entry);
+int js_word_info(struct wnn_env *env, int dic_no, int entry, struct wnn_ret_buf *ret);
+int js_word_search (struct wnn_env *env, int dic_no, w_char *yomi, struct wnn_ret_buf *ret);
+int js_word_search_by_env (struct wnn_env *env, w_char *yomi, struct wnn_ret_buf *ret);
+
+/* haven't discovered yet --yaz */
+extern WNN_JSERVER_ID *js_change_current_jserver ();
 
 #endif
 #endif  /* WNN_JSLIB_H */
--- a/Wnn/jlib/js.c	Sun Mar 02 04:48:21 2008 +0900
+++ b/Wnn/jlib/js.c	Sun Mar 02 19:07:21 2008 +0900
@@ -156,8 +156,7 @@
 }
 
 static void
-set_current_js (server)
-     register WNN_JSERVER_ID *server;
+set_current_js (register WNN_JSERVER_ID *server)
 {
   current_js = server;
   current_sd = current_js->sd;
@@ -165,7 +164,7 @@
 
 /**     デーモンが死んだ時のための後始末        **/
 static void
-daemon_dead ()
+daemon_dead (void)
 {
   current_js->js_dead = -1;
   wnn_errorno = WNN_JSERVER_DEAD;
@@ -192,8 +191,7 @@
                         (cdというのはコミュニケーションデバイスの名残)
 **/
 static int
-cd_open_un (lang)
-     register char *lang;
+cd_open_un (register char *lang)
 {
 #ifdef AF_UNIX
   int sd;
@@ -242,10 +240,7 @@
 }
 
 static int
-cd_open_in (server, lang, timeout)
-     register char *server;
-     register char *lang;
-     register int timeout;
+cd_open_in (register char *server, register char *lang, register int timeout)
 {
   int sd;
 #ifdef INET6
@@ -397,9 +392,7 @@
 
 /* get server name and return serverNo */
 static int
-_get_server_name (server, pserver)
-     char *server;
-     char *pserver;
+_get_server_name (char *server, char *pserver)
 {
   register char *p;
 #ifdef INET6
@@ -435,8 +428,7 @@
 
 /**     パケットのヘッダーを送る        **/
 static void
-snd_head (cmd)
-     int cmd;   /** cmd=コマンド **/
+snd_head (int cmd)
 {
   sbp = 0;
   put4com (cmd);
@@ -445,9 +437,7 @@
 
 /**     パケットのヘッダーを送る        **/
 static int
-snd_env_head (env, cmd)
-     register struct wnn_env *env;
-     int cmd;   /** cmd=コマンド **/
+snd_env_head (register struct wnn_env *env, int cmd)
 {
   snd_head (cmd);
   put4com (env->env_id);
@@ -456,9 +446,7 @@
 
 /**     パケットのヘッダーを送る        **/
 static int
-snd_server_head (server, cmd)
-     register WNN_JSERVER_ID *server;
-     int cmd;   /** cmd=コマンド **/
+snd_server_head (register WNN_JSERVER_ID *server, int cmd)
 {
   snd_head (cmd);
   return 0;
@@ -466,7 +454,7 @@
 
 /**     送信バッファをフラッシュする    **/
 static int
-snd_flush ()
+snd_flush (void)
 {
   if (sbp == 0)
     return (-1);
@@ -476,8 +464,7 @@
 }
 
 static int
-writen (n)
-     int n;
+writen (int n)
 {
   int cc, x;
   for (cc = 0; cc < n;)
@@ -511,8 +498,7 @@
 
 /**     サーバへ1バイト送る     **/
 static void
-put1com (c)
-     int c;
+put1com (int c)
 {
   snd_buf[sbp++] = c;
   if (sbp >= S_BUF_SIZ)
@@ -524,8 +510,7 @@
 
 /**     サーバへ2バイト送る     **/
 static void
-put2com (c)
-     int c;
+put2com (int c)
 {
   put1com (c >> (8 * 1));
   put1com (c);
@@ -533,8 +518,7 @@
 
 /**     サーバへ4バイト送る     **/
 static void
-put4com (c)
-     int c;
+put4com (int c)
 {
   put1com (c >> (8 * 3));
   put1com (c >> (8 * 2));
@@ -544,8 +528,7 @@
 
 /**     サーバへ文字列を送る    **/
 static void
-putwscom (p)
-     register w_char *p;
+putwscom (register w_char *p)
 {
   if (p == NULL)
     {
@@ -559,8 +542,7 @@
 
 /**     サーバへ文字列を送る    **/
 static void
-putscom (p)
-     register char *p;
+putscom (register char *p)
 {
   if (p == NULL)
     {
@@ -574,7 +556,7 @@
 
 /**     サーバから1バイト受ける **/
 static int
-get1com ()
+get1com (void)
 {
   static int rbp;
   static unsigned char rcv_buf[R_BUF_SIZ];      /** 受信 **/
@@ -623,7 +605,7 @@
 
 /**     サーバから2バイト受ける **/
 static int
-get2com ()
+get2com (void)
 {
   register int h;
   h = get1com ();
@@ -632,7 +614,7 @@
 
 /**     サーバから4バイト受ける **/
 static int
-get4com ()
+get4com (void)
 {
   register int h1, h2, h3;
   h1 = get1com () << 24;
@@ -643,8 +625,7 @@
 
 /**     サーバへ文字列を送る    **/
 static void
-getscom (p)
-     register char *p;
+getscom (register char *p)
 {
     while ((*p++ = get1com ()))
     ;
@@ -652,8 +633,7 @@
 
 /**     サーバへ文字列を送る    **/
 static void
-getwscom (p)
-     w_char register *p;
+getwscom (w_char register *p)
 {
     while ((*p++ = get2com ()))
     ;
@@ -663,8 +643,7 @@
 /* Moved from ../etc/string.c */
 /**     **/
 static int
-Strlen (s)
-     register w_char *s;
+Strlen (register w_char *s)
 {
   register int n;
 
@@ -674,9 +653,7 @@
 
 /**     **/
 static w_char *
-Strcpy (s1, s2)
-     register w_char *s1;
-     register w_char *s2;
+Strcpy (register w_char *s1, register w_char *s2)
 {
   register w_char *d;
 
@@ -689,8 +666,7 @@
 /*      Debug Subroutines       */
 #if DEBUG
 void
-xerror (s)
-     char *s;
+xerror (char *s)
 {
   fprintf (stderr, "%s\n", s);
 }
@@ -720,7 +696,7 @@
 
 /*      get login name form /etc/passwd file    */
 static char *
-getlogname ()
+getlogname (void)
 {
   struct passwd *getpwuid ();
   return getpwuid (getuid ())->pw_name;
@@ -741,9 +717,7 @@
 
 /**       jserver と接続する。jserver_id を返す。       **/
 WNN_JSERVER_ID *
-js_open_lang (server, lang, timeout)
-     register char *server, *lang;
-     register int timeout;
+js_open_lang (register char *server, register char *lang, register int timeout)
 {
   char *new_js;
   char host[WNN_HOSTLEN], user[WNN_ENVNAME_LEN];
@@ -828,8 +802,7 @@
 /**     ソケットをクローズする  **/
 /**       jserver との接続を close する。       **/
 int
-js_close (server)
-     WNN_JSERVER_ID *server;
+js_close (WNN_JSERVER_ID *server)
 {
   register int x;
   WNN_JSERVER_ID tmp_js_id;
@@ -862,10 +835,7 @@
 */
 
 struct wnn_env *
-js_connect_lang (server, env_name, lang)
-     register char *env_name;
-     WNN_JSERVER_ID *server;
-     char *lang;
+js_connect_lang (WNN_JSERVER_ID *server, register char *env_name, char *lang)
 {
   register int e_id;
   register struct wnn_env *env;
@@ -897,9 +867,7 @@
 #ifdef  nodef
 /* set language value to env */
 void
-js_set_lang (env, lang)
-     struct wnn_env *env;
-     register char *lang;
+js_set_lang (struct wnn_env *env, register char *lang)
 {
   register char *p;
   extern char *getenv ();
@@ -917,16 +885,13 @@
 
 /* get language value from env */
 char *
-js_get_lang (env)
-     struct wnn_env *env;
+js_get_lang (struct wnn_env *env)
 {
   return (env->lang);
 }
 
 int
-js_env_exist (server, env_name)
-     register char *env_name;
-     register WNN_JSERVER_ID *server;
+js_env_exist (register WNN_JSERVER_ID *server, register char *env_name)
 {
   set_current_js (server);
   handler_of_jserver_dead (-1);
@@ -937,8 +902,7 @@
 }
 
 int
-js_env_sticky (env)
-     register struct wnn_env *env;
+js_env_sticky (register struct wnn_env *env)
 {
   if (env == 0)
     return (-1);
@@ -950,8 +914,7 @@
 }
 
 int
-js_env_un_sticky (env)
-     register struct wnn_env *env;
+js_env_un_sticky (register struct wnn_env *env)
 {
   if (env == 0)
     return (-1);
@@ -966,8 +929,7 @@
           env で示される環境を無くす。
 **/
 int
-js_disconnect (env)
-     register struct wnn_env *env;
+js_disconnect (register struct wnn_env *env)
 {
   register int x;
   struct wnn_env tmp_env;
@@ -992,8 +954,7 @@
 
 /**     サーバとコネクトしているか      **/
 int
-js_isconnect (env)
-     register struct wnn_env *env;
+js_isconnect (register struct wnn_env *env)
 {
   if (env && env->js_id)
     return (env->js_id->js_dead);
@@ -1004,9 +965,9 @@
           env の 環境 との通信バッファを flush する。
 **/
 void
-js_flush (env)
-     struct wnn_env *env;
+js_flush (struct wnn_env *env)
 {
+    /* no operation */
 }
 
 
@@ -1140,9 +1101,7 @@
 static int rcv_file_list ();
 
 int
-js_file_list_all (server, ret)
-     WNN_JSERVER_ID *server;
-     struct wnn_ret_buf *ret;
+js_file_list_all (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret)
 {
   set_current_js (server);
   handler_of_jserver_dead (-1);
@@ -1192,10 +1151,7 @@
 
 /**     js_file_stat    **/
 int
-js_file_stat (env, path, s)
-     struct wnn_env *env;
-     char *path;
-     WNN_FILE_STAT *s;
+js_file_stat (struct wnn_env *env, char *path, WNN_FILE_STAT *s)
 {
   register int x;
   if (env == 0)
@@ -1213,10 +1169,7 @@
 
 /**     js_file_info    **/
 int
-js_file_info (env, fid, file)
-     struct wnn_env *env;
-     int fid;
-     register WNN_FILE_INFO_STRUCT *file;
+js_file_info (struct wnn_env *env, int fid, register WNN_FILE_INFO_STRUCT *file)
 {
   register int x;
   if (env == 0)
@@ -1242,9 +1195,7 @@
 
 /**     js_file_loaded  **/
 int
-js_file_loaded (server, path)
-     WNN_JSERVER_ID *server;
-     char *path;
+js_file_loaded (WNN_JSERVER_ID *server, char *path)
 {
   register int x;
   set_current_js (server);
@@ -1261,9 +1212,7 @@
 static int file_loaded_local ();
 
 int
-js_file_loaded_local (server, path)
-     WNN_JSERVER_ID *server;
-     char *path;
+js_file_loaded_local (WNN_JSERVER_ID *server, char *path)
 {
   int x;
   set_current_js (server);
@@ -1369,12 +1318,7 @@
 
 /**     js_hindo_file_create    **/
 int
-js_hindo_file_create (env, fid, fn, comment, hpasswd)
-     struct wnn_env *env;
-     int fid;
-     char *fn;
-     w_char *comment;
-     char *hpasswd;
+js_hindo_file_create (struct wnn_env *env, int fid, char *fn, w_char *comment, char *hpasswd)
 {
   register int x;
   if (env == 0)
@@ -1395,12 +1339,7 @@
 
 /**     js_dic_file_create      **/
 int
-js_dic_file_create (env, fn, type, comment, passwd, hpasswd)
-     struct wnn_env *env;
-     char *fn;
-     w_char *comment;
-     char *passwd, *hpasswd;
-     int type;
+js_dic_file_create (struct wnn_env *env, char *fn, int type, w_char *comment, char *passwd, char *hpasswd)
 {
   register int x;
   if (env == 0)
@@ -1857,9 +1796,7 @@
 static void get_dic_info ();
 
 int
-js_dic_list_all (server, ret)
-     WNN_JSERVER_ID *server;
-     struct wnn_ret_buf *ret;
+js_dic_list_all (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret)
 {
   set_current_js (server);
   handler_of_jserver_dead (-1);
@@ -1904,8 +1841,7 @@
 }
 
 static void
-get_dic_info (dic)
-     register WNN_DIC_INFO *dic;
+get_dic_info (register WNN_DIC_INFO *dic)
 {
   dic->dic_no = get4com ();     /* dic_No */
   dic->body = get4com ();       /* body fid */
@@ -1931,11 +1867,7 @@
 
 /**     js_word_add             **/
 int
-js_word_add (env, dic_no, yomi, kanji, comment, hinshi, init_hindo)
-     struct wnn_env *env;
-     int dic_no;
-     w_char *yomi, *kanji, *comment;
-     int hinshi, init_hindo;
+js_word_add (struct wnn_env *env, int dic_no, w_char *yomi, w_char *kanji, w_char *comment, int hinshi, int init_hindo)
 {
   register int x;
   if (env == 0)
@@ -1983,11 +1915,7 @@
 static int rcv_word_data ();
 
 int
-js_word_search (env, dic_no, yomi, ret)
-     struct wnn_env *env;
-     int dic_no;
-     w_char *yomi;
-     struct wnn_ret_buf *ret;
+js_word_search (struct wnn_env *env, int dic_no, w_char *yomi, struct wnn_ret_buf *ret)
 {
   if (env == 0)
     return (-1);
@@ -2003,10 +1931,7 @@
 
 /**     js_word_search_by_env   **/
 int
-js_word_search_by_env (env, yomi, ret)
-     struct wnn_env *env;
-     w_char *yomi;
-     struct wnn_ret_buf *ret;
+js_word_search_by_env (struct wnn_env *env, w_char *yomi, struct wnn_ret_buf *ret)
 {
   if (env == 0)
     return (-1);
@@ -2049,10 +1974,7 @@
 }
 
 int
-js_word_comment_set (env, dic_no, entry, comment)
-     struct wnn_env *env;
-     int dic_no, entry;
-     w_char *comment;
+js_word_comment_set (struct wnn_env *env, int dic_no, int entry, w_char *comment)
 {
   register int x;
   if (env == 0)
@@ -2075,11 +1997,8 @@
 
 /**     rcv for word_search             **/
 static int
-rcv_word_data (ret, yomi)
-     struct wnn_ret_buf *ret;
-     w_char *yomi;              /* Yomi is not sent from server
-                                 *  (at least for the time being).
-                                 */
+rcv_word_data (struct wnn_ret_buf *ret, w_char *yomi)
+/* Yomi is not sent from server (at least for the time being). */
 {
   register int x, j_c, k_c;
   w_char *k;
@@ -2130,10 +2049,7 @@
 
 /**     js_dic_info     **/
 int
-js_dic_info (env, dic_no, ret)
-     struct wnn_env *env;
-     int dic_no;
-     register WNN_DIC_INFO *ret;
+js_dic_info (struct wnn_env *env, int dic_no, register WNN_DIC_INFO *ret)
 {
   register int x;
   if (env == 0)
@@ -2155,9 +2071,7 @@
 
 /**     js_who          **/
 int
-js_who (server, ret)
-     WNN_JSERVER_ID *server;
-     struct wnn_ret_buf *ret;
+js_who (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret)
 {
   register int i, j, c;
   WNN_JWHO *w;
@@ -2193,9 +2107,7 @@
         (ウラ技)
 **/
 int
-js_env_list (server, ret)
-     WNN_JSERVER_ID *server;
-     struct wnn_ret_buf *ret;
+js_env_list (WNN_JSERVER_ID *server, struct wnn_ret_buf *ret)
 {
   register int i, j, c;
   WNN_ENV_INFO *w;
@@ -2267,11 +2179,7 @@
 ****/
 
 static void
-put_fzk_vec (hinsi, fzk, vec, vec1)
-     int hinsi;
-     w_char *fzk;
-     int vec;
-     int vec1;
+put_fzk_vec (int hinsi, w_char *fzk, int vec, int vec1)
 {
   put4com (hinsi);
   putwscom (fzk);
@@ -2287,15 +2195,7 @@
 static void rcv_sho_kanji ();
 
 int
-js_kanren (env, yomi, hinsi, fzk, vec, vec1, vec2, rb)
-     struct wnn_env *env;
-     w_char *yomi;
-     int hinsi;
-     w_char *fzk;
-     int vec;
-     int vec1;
-     int vec2;
-     struct wnn_ret_buf *rb;
+js_kanren (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, int vec2, struct wnn_ret_buf *rb)
 {
   if (env == 0)
     return (-1);
@@ -2459,14 +2359,7 @@
         kantan
 **/
 int
-js_kantan_dai (env, yomi, hinsi, fzk, vec, vec1, rb)
-     struct wnn_env *env;
-     w_char *yomi;
-     int hinsi;
-     w_char *fzk;
-     int vec;
-     int vec1;
-     struct wnn_ret_buf *rb;
+js_kantan_dai (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb)
 {
   if (env == 0)
     return (-1);
@@ -2482,14 +2375,7 @@
 }
 
 int
-js_kantan_sho (env, yomi, hinsi, fzk, vec, vec1, rb)
-     struct wnn_env *env;
-     w_char *yomi;
-     int hinsi;
-     w_char *fzk;
-     int vec;
-     int vec1;
-     struct wnn_ret_buf *rb;
+js_kantan_sho (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb)
 {
   int sbncnt;
   if (env == 0)
@@ -2510,14 +2396,7 @@
         kanzen
 **/
 int
-js_kanzen_dai (env, yomi, hinsi, fzk, vec, vec1, rb)
-     struct wnn_env *env;
-     w_char *yomi;
-     int hinsi;
-     w_char *fzk;
-     int vec;
-     int vec1;
-     struct wnn_ret_buf *rb;
+js_kanzen_dai (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb)
 {
   if (env == 0)
     return (-1);
@@ -2533,14 +2412,7 @@
 
 
 int
-js_kanzen_sho (env, yomi, hinsi, fzk, vec, vec1, rb)
-     struct wnn_env *env;
-     w_char *yomi;
-     int hinsi;
-     w_char *fzk;
-     int vec;
-     int vec1;
-     struct wnn_ret_buf *rb;
+js_kanzen_sho (struct wnn_env *env, w_char *yomi, int hinsi, w_char *fzk, int vec, int vec1, struct wnn_ret_buf *rb)
 {
   int sbncnt;
   if (env == 0)
@@ -2558,9 +2430,7 @@
 
 /**     js_version              **/
 int
-js_version (server, serv, libv)
-     int *serv, *libv;
-     WNN_JSERVER_ID *server;
+js_version (WNN_JSERVER_ID *server, int *serv, int *libv)
 {
   set_current_js (server);
   handler_of_jserver_dead (-1);
@@ -2571,9 +2441,7 @@
 }
 
 static void
-re_alloc (ret, size)
-     register struct wnn_ret_buf *ret;
-     int size;
+re_alloc (register struct wnn_ret_buf *ret, int size)
 {
   if (ret->size < size)
     {
@@ -2586,8 +2454,7 @@
 
 
 int
-js_kill (server)
-     WNN_JSERVER_ID *server;
+js_kill (WNN_JSERVER_ID *server)
 {
   int x;
   set_current_js (server);
@@ -2600,9 +2467,7 @@
 
 
 int
-js_file_remove (server, n, pwd)
-     WNN_JSERVER_ID *server;
-     char *n, *pwd;
+js_file_remove (WNN_JSERVER_ID *server, char *n, char *pwd)
 {
   register int x;
   set_current_js (server);
@@ -2620,9 +2485,7 @@
 }
 
 int
-js_file_remove_client (server, n, pwd)
-     WNN_JSERVER_ID *server;
-     char *n, *pwd;
+js_file_remove_client (WNN_JSERVER_ID *server, char *n, char *pwd)
 {
   struct wnn_file_head fh;
   register FILE *fp;
@@ -2663,12 +2526,7 @@
 
 /**     js_dic_file_create_client       **/
 int
-js_dic_file_create_client (env, fn, type, com, passwd, hpasswd)
-     struct wnn_env *env;
-     int type;
-     char *fn;
-     w_char *com;
-     char *passwd, *hpasswd;
+js_dic_file_create_client (struct wnn_env *env, char *fn, int type, w_char *com, char *passwd, char *hpasswd)
 {
   int x;
   if (type != WNN_REV_DICT && type != CWNN_REV_DICT && type != BWNN_REV_DICT && type != WNN_UD_DICT)
@@ -2688,12 +2546,7 @@
 
 /**     js_hindo_file_create_client     **/
 int
-js_hindo_file_create_client (env, fid, fn, com, hpasswd)
-     struct wnn_env *env;
-     int fid;
-     char *fn;
-     w_char *com;
-     char *hpasswd;
+js_hindo_file_create_client (struct wnn_env *env, int fid, char *fn, w_char *com, char *hpasswd)
 {
   register int x;
   struct wnn_file_uniq funiq;
@@ -2731,10 +2584,7 @@
 }
 
 int
-js_file_comment_set (env, fid, comment)
-     struct wnn_env *env;
-     int fid;
-     w_char *comment;
+js_file_comment_set (struct wnn_env *env, int fid, w_char *comment)
 {
   register int x;
   if (env == 0)
@@ -2760,10 +2610,7 @@
  */
 
 int
-js_hinsi_name (server, no, rb)
-     WNN_JSERVER_ID *server;
-     int no;
-     struct wnn_ret_buf *rb;
+js_hinsi_name (WNN_JSERVER_ID *server, int no, struct wnn_ret_buf *rb)
 {
   register int size;
 
@@ -2784,9 +2631,7 @@
 
 
 int
-js_hinsi_number (server, name)
-     WNN_JSERVER_ID *server;
-     w_char *name;
+js_hinsi_number (WNN_JSERVER_ID *server, w_char *name)
 {
   register int no;
 
@@ -2805,11 +2650,7 @@
 
 
 int
-js_hinsi_list (env, dic_no, name, rb)
-     struct wnn_env *env;
-     int dic_no;
-     w_char *name;
-     struct wnn_ret_buf *rb;
+js_hinsi_list (struct wnn_env *env, int dic_no, w_char *name, struct wnn_ret_buf *rb)
 {
   int size;
   int count;
@@ -2914,10 +2755,7 @@
 }
 
 int
-js_hinsi_table_set (env, dic_no, hinsi_table)
-     struct wnn_env *env;
-     int dic_no;
-     w_char *hinsi_table;
+js_hinsi_table_set (struct wnn_env *env, int dic_no, w_char *hinsi_table)
 {
   int x;
   if (env == 0)