aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/option.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r--src/nvim/option.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c
index 5517768194..fc1fab834e 100644
--- a/src/nvim/option.c
+++ b/src/nvim/option.c
@@ -4168,7 +4168,8 @@ static char *set_num_option(int opt_idx, char_u *varp, long value,
errmsg = e_positive;
}
} else if (pp == &p_ch) {
- if (value < 1) {
+ int minval = ui_has(kUIMessages) ? 0 : 1;
+ if (value < minval) {
errmsg = e_positive;
}
} else if (pp == &p_tm) {
@@ -4276,6 +4277,9 @@ static char *set_num_option(int opt_idx, char_u *varp, long value,
p_window = Rows - 1;
}
} else if (pp == &p_ch) {
+ if (ui_has(kUIMessages)) {
+ p_ch = 0;
+ }
if (p_ch > Rows - min_rows() + 1) {
p_ch = Rows - min_rows() + 1;
}