X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;ds=sidebyside;f=client_common.c;h=c2ae2d315fc650f0e4fc6bd1dc267d34800a2983;hb=786010c598f79d20280e6ea9ea458cad4a7e9af7;hp=330c9f7028b9b67fbddaad39ec4dd843a8ec4d8d;hpb=a1e58132eacf841001b1caf29ea6964e3e28adfd;p=paraslash.git diff --git a/client_common.c b/client_common.c index 330c9f70..c2ae2d31 100644 --- a/client_common.c +++ b/client_common.c @@ -27,6 +27,7 @@ #include "net.h" #include "fd.h" #include "string.h" +#include "client.cmdline.h" #include "client.h" #include "error.h" @@ -67,7 +68,7 @@ int client_parse_config(int argc, char *argv[], para_calloc(sizeof(struct private_client_data)); pcd->fd = -1; - cmdline_parser(argc, argv, &pcd->conf); + client_cmdline_parser(argc, argv, &pcd->conf); ret = - E_CLIENT_SYNTAX; if (!pcd->conf.inputs_num) goto out; @@ -87,7 +88,8 @@ int client_parse_config(int argc, char *argv[], goto out; } if (!ret) - cmdline_parser_configfile(pcd->config_file, &pcd->conf, 0, 0, 0); + client_cmdline_parser_configfile(pcd->config_file, + &pcd->conf, 0, 0, 0); ret = 1; *pcd_ptr = pcd; PARA_INFO_LOG( @@ -111,7 +113,6 @@ void client_pre_select(struct sched *s, struct task *t) { struct private_client_data *pcd = t->private_data; - PARA_INFO_LOG("status %d\n", pcd->status); t->ret = 1; pcd->check_r = 0; pcd->check_w = 0; @@ -171,7 +172,7 @@ void client_post_select(struct sched *s, struct task *t) { struct private_client_data *pcd = t->private_data; - PARA_INFO_LOG("status %d\n", pcd->status); +// PARA_INFO_LOG("status %d\n", pcd->status); t->ret = 1; if (pcd->fd < 0) return; @@ -228,7 +229,7 @@ void client_post_select(struct sched *s, struct task *t) if (t->ret < 0) return; bytes_received = t->ret; - PARA_INFO_LOG("++++ server info ++++\n%s\n++++ end of server " + PARA_DEBUG_LOG("++++ server info ++++\n%s\n++++ end of server " "info ++++\n", pcd->buf); /* check if server has sent "Proceed" message */ t->ret = -E_CLIENT_AUTH; @@ -259,7 +260,7 @@ void client_post_select(struct sched *s, struct task *t) free(tmp); } command = para_strcat(command, EOC_MSG "\n"); - PARA_INFO_LOG("--> %s\n", command); + PARA_DEBUG_LOG("--> %s\n", command); t->ret = send_buffer(pcd->fd, command); free(command); if (t->ret > 0)