summaryrefslogtreecommitdiff
path: root/src/common/completion.c
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2005-12-20 11:47:24 +0000
committerSebastien Helleu <flashcode@flashtux.org>2005-12-20 11:47:24 +0000
commit7c1c8cd874012939b4a4657cebe004c618f30558 (patch)
treef3600a43c56f5b2afdceb81705308f357c690899 /src/common/completion.c
parentd280bf2a92b9cdc89a99eebf410d6602d35e1cda (diff)
downloadweechat-7c1c8cd874012939b4a4657cebe004c618f30558.zip
Fixed completion bugs with nick completion in commmands ("%n")
Diffstat (limited to 'src/common/completion.c')
-rw-r--r--src/common/completion.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/common/completion.c b/src/common/completion.c
index a09cfd51b..55c4932d4 100644
--- a/src/common/completion.c
+++ b/src/common/completion.c
@@ -52,6 +52,7 @@ completion_init (t_completion *completion, void *server, void *channel)
completion->context = COMPLETION_NULL;
completion->base_command = NULL;
completion->base_command_arg = 0;
+ completion->arg_is_nick = 0;
completion->position = -1;
completion->base_word = NULL;
completion->args = NULL;
@@ -351,6 +352,7 @@ completion_list_add_channel_nicks (t_completion *completion)
&completion->last_completion,
((t_irc_channel *)(completion->channel))->name);
}
+ completion->arg_is_nick = 1;
}
}
@@ -1135,7 +1137,7 @@ completion_search (t_completion *completion, char *buffer, int size, int pos)
break;
case COMPLETION_COMMAND_ARG:
if (completion->completion_list)
- completion_command_arg (completion, 0);
+ completion_command_arg (completion, completion->arg_is_nick);
else
completion_nick (completion);
break;