1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-26 21:06:38 +02:00

fset: fix refresh of buffer when options are added/removed

This commit is contained in:
Sébastien Helleu
2017-05-28 15:52:25 +02:00
parent a240115baf
commit fb363eb723
3 changed files with 39 additions and 21 deletions
+2 -4
View File
@@ -93,8 +93,7 @@ fset_command_fset (const void *pointer, void *data,
value = 1;
}
num_options = weechat_arraylist_size (fset_options);
if ((fset_buffer_selected_line >= 0)
&& (num_options > 0))
if (num_options > 0)
{
line = fset_buffer_selected_line - value;
if (line < 0)
@@ -122,8 +121,7 @@ fset_command_fset (const void *pointer, void *data,
value = 1;
}
num_options = weechat_arraylist_size (fset_options);
if ((fset_buffer_selected_line >= 0)
&& (num_options > 0))
if (num_options > 0)
{
line = fset_buffer_selected_line + value;
if (line >= num_options)