Bump liberty

This commit is contained in:
2015-07-11 17:54:38 +02:00
parent e57939e705
commit 0c4b727961
5 changed files with 49 additions and 142 deletions

View File

@@ -378,7 +378,8 @@ irc_initialize_ssl (struct bot_context *ctx, struct error **e)
const char *ssl_cert = str_map_find (&ctx->config, "ssl_cert");
if (ssl_cert)
{
char *path = resolve_config_filename (ssl_cert);
char *path = resolve_filename
(ssl_cert, resolve_relative_config_filename);
if (!path)
print_error ("%s: %s", "cannot open file", ssl_cert);
// XXX: perhaps we should read the file ourselves for better messages
@@ -1141,10 +1142,10 @@ plugin_load_all_from_config (struct bot_context *ctx)
struct str_vector plugins;
str_vector_init (&plugins);
split_str_ignore_empty (plugin_list, ',', &plugins);
cstr_split_ignore_empty (plugin_list, ',', &plugins);
for (size_t i = 0; i < plugins.len; i++)
{
char *name = strip_str_in_place (plugins.vector[i], " ");
char *name = cstr_strip_in_place (plugins.vector[i], " ");
struct error *e = NULL;
if (!plugin_load (ctx, name, &e))
@@ -1181,10 +1182,10 @@ parse_bot_command (const char *s, const char *command, const char **following)
static void
split_bot_command_argument_list (const char *arguments, struct str_vector *out)
{
split_str_ignore_empty (arguments, ',', out);
cstr_split_ignore_empty (arguments, ',', out);
for (size_t i = 0; i < out->len; )
{
if (!*strip_str_in_place (out->vector[i], " \t"))
if (!*cstr_strip_in_place (out->vector[i], " \t"))
str_vector_remove (out, i);
else
i++;