Do not warn when the configuration file contains 256-color values
authorMikael Berthe <mikael@lilotux.net>
Thu, 11 Oct 2012 22:46:41 +0200
changeset 2029 ca40744c03be
parent 2028 7b5bd6ad83b4
child 2030 0771e130f79d
Do not warn when the configuration file contains 256-color values Configuration file is read before ncurses is initialized so we cannot assume the terminal doesn't support 256 colors.
mcabber/mcabber/screen.c
--- a/mcabber/mcabber/screen.c	Thu Oct 11 22:44:34 2012 +0200
+++ b/mcabber/mcabber/screen.c	Thu Oct 11 22:46:41 2012 +0200
@@ -242,7 +242,7 @@
 
   // Directly support 256-color values
   result = atoi(name);
-  if (result > 0 && result < COLORS)
+  if (result > 0 && (result < COLORS || !Curses))
     return result;
 
   scr_LogPrint(LPRINT_LOGNORM, "ERROR: Wrong color: %s", name);