diff options
author | Emanuele Giaquinta <exg@irssi.org> | 2008-05-23 09:47:40 +0000 |
---|---|---|
committer | exg <exg@dbcabf3a-b0e7-0310-adc4-f8d773084564> | 2008-05-23 09:47:40 +0000 |
commit | 54f5beb8f5b0c98db5363f006e9d46753f30a704 (patch) | |
tree | 6b1e3199a44629ab59301971b63990adb2c53ac6 /src/fe-common | |
parent | 8e8d46f2118ae19557fa9451a96a77d3a7734eed (diff) | |
download | irssi-54f5beb8f5b0c98db5363f006e9d46753f30a704.zip |
Do nothing in word_complete if erase is true and we are not continuing
a completion.
git-svn-id: file:///var/www/svn.irssi.org/SVN/irssi/trunk@4844 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'src/fe-common')
-rw-r--r-- | src/fe-common/core/completion.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/fe-common/core/completion.c b/src/fe-common/core/completion.c index a5bf609b..a8eab9bd 100644 --- a/src/fe-common/core/completion.c +++ b/src/fe-common/core/completion.c @@ -143,6 +143,9 @@ char *word_complete(WINDOW_REC *window, const char *line, int *pos, int erase, i continue_complete = complist != NULL && *pos == last_line_pos && strcmp(line, last_line) == 0; + if (erase && !continue_complete) + return NULL; + old_startpos = startpos; old_wordlen = wordlen; @@ -193,9 +196,6 @@ char *word_complete(WINDOW_REC *window, const char *line, int *pos, int erase, i if (erase) { signal_emit("complete erase", 3, window, word, linestart); - if (!continue_complete) - return NULL; - /* jump to next completion */ word = NULL; linestart = NULL; |