@@ -3860,19 +3860,22 @@ static buf_T *do_sub(exarg_T *eap, proftime_T timeout, bool do_buf_event, handle
3860
3860
prompt = xmallocz(ec + 1);
3861
3861
memset(prompt, ' ', sc);
3862
3862
memset(prompt + sc, '^', ec - sc + 1);
3863
-
resp = (char_u *)getcmdline_prompt(NUL, prompt, 0, EXPAND_NOTHING,
3863
+
resp = (char_u *)getcmdline_prompt(-1, prompt, 0, EXPAND_NOTHING,
3864
3864
NULL, CALLBACK_NONE);
3865
3865
msg_putchar('\n');
3866
3866
xfree(prompt);
3867
3867
if (resp != NULL) {
3868
3868
typed = *resp;
3869
3869
xfree(resp);
3870
-
// When ":normal" runs out of characters we get
3871
-
// an empty line. Use "q" to get out of the
3872
-
// loop.
3873
-
if (ex_normal_busy && typed == NUL) {
3874
-
typed = 'q';
3875
-
}
3870
+
} else {
3871
+
// getcmdline_prompt() returns NULL if there is no command line to return.
3872
+
typed = NUL;
3873
+
}
3874
+
// When ":normal" runs out of characters we get
3875
+
// an empty line. Use "q" to get out of the
3876
+
// loop.
3877
+
if (ex_normal_busy && typed == NUL) {
3878
+
typed = 'q';
3876
3879
}
3877
3880
} else {
3878
3881
char_u *orig_line = NULL;
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4