diff src/libvterm/src/pen.c @ 20555:eedaa9a30ab4 v8.2.0831

patch 8.2.0831: compiler warnings for integer sizes Commit: https://github.com/vim/vim/commit/f4b68e9056f8ddb64c3d7141df138fe099575abf Author: Bram Moolenaar <Bram@vim.org> Date: Wed May 27 21:22:14 2020 +0200 patch 8.2.0831: compiler warnings for integer sizes Problem: Compiler warnings for integer sizes. Solution: Add type casts. (Mike Williams)
author Bram Moolenaar <Bram@vim.org>
date Wed, 27 May 2020 21:30:04 +0200
parents a4652d7ec99f
children bc81b275d4d6
line wrap: on
line diff
--- a/src/libvterm/src/pen.c
+++ b/src/libvterm/src/pen.c
@@ -47,7 +47,7 @@ static void lookup_default_colour_ansi(l
   vterm_color_rgb(
       col,
       ansi_colors[idx].red, ansi_colors[idx].green, ansi_colors[idx].blue);
-  col->index = idx;
+  col->index = (uint8_t)idx;
   col->type = VTERM_COLOR_INDEXED;
 }
 
@@ -96,7 +96,7 @@ static int lookup_colour(const VTermStat
     if(argcount < 3)
       return argcount;
 
-    vterm_color_rgb(col, CSI_ARG(args[0]), CSI_ARG(args[1]), CSI_ARG(args[2]));
+    vterm_color_rgb(col, (uint8_t)CSI_ARG(args[0]), (uint8_t)CSI_ARG(args[1]), (uint8_t)CSI_ARG(args[2]));
 
     return 3;