1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-12 14:14:48 +02:00

core: add condition on new_tags in functions gui_buffer_set_highlight_tags_restrict and gui_buffer_set_highlight_tags

This commit is contained in:
Sébastien Helleu
2025-11-23 10:14:10 +01:00
parent c248aa42ce
commit 1f0d8d3849
+2 -2
View File
@@ -2177,7 +2177,7 @@ gui_buffer_set_highlight_tags_restrict (struct t_gui_buffer *buffer,
}
buffer->highlight_tags_restrict_count = 0;
if (!new_tags)
if (!new_tags || !new_tags[0])
return;
buffer->highlight_tags_restrict = strdup (new_tags);
@@ -2212,7 +2212,7 @@ gui_buffer_set_highlight_tags (struct t_gui_buffer *buffer,
}
buffer->highlight_tags_count = 0;
if (!new_tags)
if (!new_tags || !new_tags[0])
return;
buffer->highlight_tags = strdup (new_tags);