mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-04 10:41:11 +02:00
24542: fix RC_QUOTES completion if opening quote not at start of string
This commit is contained in:
parent
154b57fdb6
commit
f6f8152f4b
2 changed files with 16 additions and 5 deletions
|
@ -1,3 +1,9 @@
|
|||
2008-02-09 Peter Stephenson <p.w.stephenson@ntlworld.com>
|
||||
|
||||
* 24542: Src/Zle/zle_tricky.c: RC_QUOTES wasn't handled
|
||||
if the opening quote wasn't at the start of the word, causing
|
||||
endless looping.
|
||||
|
||||
2008-02-07 Clint Adams <clint@zsh.org>
|
||||
|
||||
* unposted: Functions/Misc/run-help-git,
|
||||
|
|
|
@ -1230,11 +1230,16 @@ get_comp_string(void)
|
|||
/* This is done when the lexer reached the word the cursor is on. */
|
||||
tt = tokstr ? dupstring(tokstr) : NULL;
|
||||
|
||||
if (isset(RCQUOTES) && *tt == Snull) {
|
||||
char *p, *e = tt + zlemetacs - wb;
|
||||
for (p = tt; *p && p < e; p++)
|
||||
if (*p == '\'')
|
||||
qsub++;
|
||||
if (isset(RCQUOTES)) {
|
||||
char *tt1, *e = tt + zlemetacs - wb;
|
||||
for (tt1 = tt; *tt1; tt1++) {
|
||||
if (*tt1 == Snull) {
|
||||
char *p;
|
||||
for (p = tt1; *p && p < e; p++)
|
||||
if (*p == '\'')
|
||||
qsub++;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* If we added a `x', remove it. */
|
||||
if (addedx && tt)
|
||||
|
|
Loading…
Reference in a new issue