diff src/terminal.c @ 16312:46e8430738fa v8.1.1161

patch 8.1.1161: unreachable code commit https://github.com/vim/vim/commit/1d79ce81e7be20405f0fa9687b37c86a2215e326 Author: Bram Moolenaar <Bram@vim.org> Date: Fri Apr 12 22:27:39 2019 +0200 patch 8.1.1161: unreachable code Problem: Unreachable code. Solution: Remove condition that will never be true. Add tests for all ANSI colors.
author Bram Moolenaar <Bram@vim.org>
date Fri, 12 Apr 2019 22:30:08 +0200
parents 1298cb5c1f72
children b3bc3ba07bef
line wrap: on
line diff
--- a/src/terminal.c
+++ b/src/terminal.c
@@ -2432,10 +2432,7 @@ color2index(VTermColor *color, int fg, i
 
     if (color->ansi_index != VTERM_ANSI_INDEX_NONE)
     {
-	/* First 16 colors and default: use the ANSI index, because these
-	 * colors can be redefined, we use the RGB values. */
-	if (t_colors > 256)
-	    return color->ansi_index;
+	// The first 16 colors and default: use the ANSI index.
 	switch (color->ansi_index)
 	{
 	    case  0: return 0;