summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/plugins/buflist/buflist-bar-item.c3
-rw-r--r--src/plugins/fset/fset-command.c3
-rw-r--r--src/plugins/irc/irc-ctcp.c3
-rw-r--r--src/plugins/logger/logger-backlog.c3
-rw-r--r--src/plugins/logger/logger-tail.c3
5 files changed, 5 insertions, 10 deletions
diff --git a/src/plugins/buflist/buflist-bar-item.c b/src/plugins/buflist/buflist-bar-item.c
index ac3fbe062..dcfa55503 100644
--- a/src/plugins/buflist/buflist-bar-item.c
+++ b/src/plugins/buflist/buflist-bar-item.c
@@ -372,8 +372,7 @@ buflist_bar_item_buflist_cb (const void *pointer, void *data,
snprintf (str_format_number_empty, sizeof (str_format_number_empty),
"%%-%ds", length_max_number);
- if (buflist_list_buffers[item_index])
- weechat_arraylist_free (buflist_list_buffers[item_index]);
+ weechat_arraylist_free (buflist_list_buffers[item_index]);
buflist_list_buffers[item_index] = weechat_arraylist_new (
16, 0, 1,
NULL, NULL, NULL, NULL);
diff --git a/src/plugins/fset/fset-command.c b/src/plugins/fset/fset-command.c
index ec0f5e25d..7e60995ac 100644
--- a/src/plugins/fset/fset-command.c
+++ b/src/plugins/fset/fset-command.c
@@ -567,8 +567,7 @@ fset_command_run_set_cb (const void *pointer, void *data,
/* check condition to trigger the fset buffer */
if (condition_ok)
{
- if (old_options)
- weechat_arraylist_free (old_options);
+ weechat_arraylist_free (old_options);
free (old_max_length);
free (old_filter);
diff --git a/src/plugins/irc/irc-ctcp.c b/src/plugins/irc/irc-ctcp.c
index 619a16f1e..a34f28c57 100644
--- a/src/plugins/irc/irc-ctcp.c
+++ b/src/plugins/irc/irc-ctcp.c
@@ -495,8 +495,7 @@ end:
free (dup_ctcp);
free (dup_ctcp_upper);
free (dup_args);
- if (list_messages)
- weechat_arraylist_free (list_messages);
+ weechat_arraylist_free (list_messages);
}
/*
diff --git a/src/plugins/logger/logger-backlog.c b/src/plugins/logger/logger-backlog.c
index 6f211b382..1bb015460 100644
--- a/src/plugins/logger/logger-backlog.c
+++ b/src/plugins/logger/logger-backlog.c
@@ -243,8 +243,7 @@ logger_backlog_group_messages (struct t_arraylist *lines)
error:
free (message);
- if (messages)
- weechat_arraylist_free (messages);
+ weechat_arraylist_free (messages);
return NULL;
}
diff --git a/src/plugins/logger/logger-tail.c b/src/plugins/logger/logger-tail.c
index fec93873e..9263b5e7f 100644
--- a/src/plugins/logger/logger-tail.c
+++ b/src/plugins/logger/logger-tail.c
@@ -233,8 +233,7 @@ logger_tail_file (const char *filename, int lines)
error:
free (part_of_line);
- if (list_lines)
- weechat_arraylist_free (list_lines);
+ weechat_arraylist_free (list_lines);
if (fd >= 0)
close (fd);
return NULL;