summaryrefslogtreecommitdiffstats
path: root/src/ex_getln.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2007-07-28 12:21:47 +0000
committerBram Moolenaar <Bram@vim.org>2007-07-28 12:21:47 +0000
commit7662423e10ca5762356eba039b6a5d922e84cd4d (patch)
tree23d48dd4b483ec74440b4b4ee6ee4709f0a50eeb /src/ex_getln.c
parent2240aeb4cb1d1465e20e9e2de07220dc11da98c6 (diff)
updated for version 7.1-043v7.1.043
Diffstat (limited to 'src/ex_getln.c')
-rw-r--r--src/ex_getln.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ex_getln.c b/src/ex_getln.c
index a5975e9868..206da80651 100644
--- a/src/ex_getln.c
+++ b/src/ex_getln.c
@@ -2095,11 +2095,11 @@ getexmodeline(promptc, dummy, indent)
garray_T line_ga;
char_u *pend;
int startcol = 0;
- int c1;
+ int c1 = 0;
int escaped = FALSE; /* CTRL-V typed */
int vcol = 0;
char_u *p;
- int prev_char = 0;
+ int prev_char;
/* Switch cursor on now. This avoids that it happens after the "\n", which
* confuses the system function that computes tabstops. */
@@ -2152,6 +2152,7 @@ getexmodeline(promptc, dummy, indent)
/* Get one character at a time. Don't use inchar(), it can't handle
* special characters. */
+ prev_char = c1;
c1 = vgetc();
/*
@@ -2209,7 +2210,6 @@ add_indent:
redraw:
/* redraw the line */
msg_col = startcol;
- windgoto(msg_row, msg_col);
vcol = 0;
for (p = (char_u *)line_ga.ga_data;
p < (char_u *)line_ga.ga_data + line_ga.ga_len; ++p)
@@ -2228,6 +2228,7 @@ redraw:
}
}
msg_clr_eos();
+ windgoto(msg_row, msg_col);
continue;
}
@@ -2273,7 +2274,6 @@ redraw:
if (IS_SPECIAL(c1))
c1 = '?';
((char_u *)line_ga.ga_data)[line_ga.ga_len] = c1;
- prev_char = c1;
if (c1 == '\n')
msg_putchar('\n');
else if (c1 == TAB)