check tty in can_set_perm_invent
During very early startup, Windows may not have loaded the tty window procs yet, and it is running with safeprocs. It will eventually load the tty stuff. If the currently operating window port fails in can_set_perm_invent(), try the check for WC_PERM_INVENT again explicitly on the tty windowport.
This commit is contained in:
@@ -5155,9 +5155,16 @@ can_set_perm_invent(void)
|
||||
* and is about to be changed to True.
|
||||
*/
|
||||
uchar old_perminv_mode = iflags.perminv_mode;
|
||||
|
||||
if (!(windowprocs.wincap & WC_PERM_INVENT))
|
||||
return FALSE; /* should never happen */
|
||||
if (!(windowprocs.wincap & WC_PERM_INVENT)) {
|
||||
#ifdef TTY_GRAPHICS
|
||||
#ifdef TTY_PERM_INVENT
|
||||
/* check tty, not necessarily the active window port;
|
||||
windows early startup can still be set to safeprocs */
|
||||
if (!check_tty_wincap(WC_PERM_INVENT))
|
||||
#endif
|
||||
#endif
|
||||
return FALSE; /* should never happen */
|
||||
}
|
||||
|
||||
if (iflags.perminv_mode == InvOptNone)
|
||||
iflags.perminv_mode = InvOptOn;
|
||||
|
||||
Reference in New Issue
Block a user