From 12e71eb8a89bdfe1def5854fd7478e8899801b44 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Thu, 6 Jun 2019 15:19:31 +0200 Subject: [PATCH] patch 8.1.1481: length for two-digit rgb termresponse is off by one Problem: Length for two-digit rgb termresponse is off by one. Solution: Adjust the length. (closes #4494) --- src/term.c | 2 +- src/version.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/term.c b/src/term.c index 8d6a98e5c..afa622e45 100644 --- a/src/term.c +++ b/src/term.c @@ -4990,7 +4990,7 @@ check_termcode( int is_4digit = i - j >= 21 && tp[j + 11] == '/' && tp[j + 16] == '/'; - if (i - j >= 14 && STRNCMP(tp + j + 3, "rgb:", 4) == 0 + if (i - j >= 15 && STRNCMP(tp + j + 3, "rgb:", 4) == 0 && (is_4digit || (tp[j + 9] == '/' && tp[i + 12 == '/']))) { diff --git a/src/version.c b/src/version.c index 72f4009ff..2fd64c3f4 100644 --- a/src/version.c +++ b/src/version.c @@ -767,6 +767,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 1481, /**/ 1480, /**/ -- 2.40.0