/****************************************************************************
- * Copyright (c) 1998-2013,2014 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2015,2016 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
#define CUR SP_TERMTYPE
#endif
-MODULE_ID("$Id: lib_color.c,v 1.110 2014/03/08 20:04:44 tom Exp $")
+MODULE_ID("$Id: lib_color.c,v 1.113 2016/05/07 23:50:54 tom Exp $")
#ifdef USE_TERM_DRIVER
#define CanChange InfoOf(SP_PARM).canchange
SP_PARM->_color_pairs[pair] = result;
if (GET_SCREEN_PAIR(SP_PARM) == pair)
- SET_SCREEN_PAIR(SP_PARM, (chtype) (~0)); /* force attribute update */
+ SET_SCREEN_PAIR(SP_PARM, (int) (~0)); /* force attribute update */
#ifdef USE_TERM_DRIVER
CallDriver_3(SP_PARM, td_initpair, pair, f, b);
}
} else {
reset_color_pair(NCURSES_SP_ARG);
- if (old_pair < 0)
+ if (old_pair < 0 && pair <= 0)
return;
}