used by the amp filter to pre-amplify the audio stream.
- fix a close-without-open bug in para_write.
- fix a bug in com_init() which was introduced in 0.3.2.
+ - better error diagnostics for para_client.
-----------------------------------------
0.3.2 (2008-04-11) "probabilistic parity"
s.default_timeout.tv_sec = 1;
s.default_timeout.tv_usec = 0;
ret = client_open(argc, argv, &ct);
- if (ret < 0) /* can not use PARA_LOG here */
+ if (ret < 0) /* can not use PARA_LOG here because ct is NULL */
exit(EXIT_FAILURE);
register_task(&svt);
ret = schedule(&s);
# file client.conf
+args "--no-handle-error"
option "hostname" i "ip or host to connect" string typestr="host" default="localhost" optional
option "user" u "paraslash username" string typestr="username" default="<current user>" optional
option "server_port" p "port to connect" int typestr="port" default="2990" optional
*ct_ptr = ct;
ct->fd = -1;
- ret = client_cmdline_parser(argc, argv, &ct->conf);
+ ret = -E_CLIENT_SYNTAX;
+ if (client_cmdline_parser(argc, argv, &ct->conf))
+ goto out;
HANDLE_VERSION_FLAG("client", ct->conf);
ret = -E_CLIENT_SYNTAX;
if (!ct->conf.inputs_num)
.override = 0,
.initialize = 0,
.check_required = 0,
- .check_ambiguity = 0
+ .check_ambiguity = 0,
+ .print_errors = 0
};
- client_cmdline_parser_config_file(ct->config_file,
- &ct->conf, ¶ms);
+ ret = -E_BAD_CONFIG;
+ if (client_cmdline_parser_config_file(ct->config_file,
+ &ct->conf, ¶ms))
+ goto out;
}
ret = 1;
PARA_INFO_LOG("loglevel: %d\n", ct->conf.loglevel_arg);
}
return ret;
}
-
PARA_ERROR(CLIENT_SYNTAX, "syntax error"), \
PARA_ERROR(INVALID_CHALLENGE, "did not receive valid challenge"), \
PARA_ERROR(NO_CONFIG, "config file not found"), \
+ PARA_ERROR(BAD_CONFIG, "syntax error in config file"), \
PARA_ERROR(CLIENT_AUTH, "authentication failed"), \
PARA_ERROR(SERVER_EOF, "connection closed by para_server"), \