From ec898732a17e9652181d7059489e85f4fd89a34c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Tue, 4 Aug 2020 22:42:59 +0200 Subject: [PATCH] core: rename functions to allocate/free lines --- src/gui/gui-buffer.c | 4 ++-- src/gui/gui-line.c | 6 +++--- src/gui/gui-line.h | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/gui/gui-buffer.c b/src/gui/gui-buffer.c index a35cc620d..951f2b478 100644 --- a/src/gui/gui-buffer.c +++ b/src/gui/gui-buffer.c @@ -717,7 +717,7 @@ gui_buffer_new (struct t_weechat_plugin *plugin, new_buffer->title = NULL; /* chat content */ - new_buffer->own_lines = gui_lines_alloc (); + new_buffer->own_lines = gui_line_lines_alloc (); new_buffer->mixed_lines = NULL; new_buffer->lines = new_buffer->own_lines; new_buffer->time_for_each_line = 1; @@ -3659,7 +3659,7 @@ gui_buffer_unmerge (struct t_gui_buffer *buffer, int number) { /* only one buffer will remain, so it will not be merged any more */ gui_line_mixed_free_all (buffer); - gui_lines_free (buffer->mixed_lines); + gui_line_lines_free (buffer->mixed_lines); for (ptr_buffer = gui_buffers; ptr_buffer; ptr_buffer = ptr_buffer->next_buffer) { diff --git a/src/gui/gui-line.c b/src/gui/gui-line.c index 8e634ddba..cbf1aa375 100644 --- a/src/gui/gui-line.c +++ b/src/gui/gui-line.c @@ -54,7 +54,7 @@ */ struct t_gui_lines * -gui_lines_alloc () +gui_line_lines_alloc () { struct t_gui_lines *new_lines; @@ -81,7 +81,7 @@ gui_lines_alloc () */ void -gui_lines_free (struct t_gui_lines *lines) +gui_line_lines_free (struct t_gui_lines *lines) { if (!lines) return; @@ -1787,7 +1787,7 @@ gui_line_mix_buffers (struct t_gui_buffer *buffer) return; /* mix all lines (sorting by date) to a new structure "new_lines" */ - new_lines = gui_lines_alloc (); + new_lines = gui_line_lines_alloc (); if (!new_lines) return; ptr_line1 = ptr_buffer_found->lines->first_line; diff --git a/src/gui/gui-line.h b/src/gui/gui-line.h index 9e5d5e14d..9583cf338 100644 --- a/src/gui/gui-line.h +++ b/src/gui/gui-line.h @@ -69,8 +69,8 @@ struct t_gui_lines /* line functions */ -extern struct t_gui_lines *gui_lines_alloc (); -extern void gui_lines_free (struct t_gui_lines *lines); +extern struct t_gui_lines *gui_line_lines_alloc (); +extern void gui_line_lines_free (struct t_gui_lines *lines); extern void gui_line_tags_alloc (struct t_gui_line_data *line_data, const char *tags); extern void gui_line_tags_free (struct t_gui_line_data *line_data);