From df5596f65f96c55f385ec0a869baeec2109500d2 Mon Sep 17 00:00:00 2001 From: Jason Hood Date: Sat, 28 Oct 2017 12:31:35 +1000 Subject: [PATCH] Increase cache to five handles The cache is used to speed up detection of console handles, but with the original three handles I was only thinking of actual console handles, not general file handles. Five handles implies: stdout, stderr, CONOUT$, log file and output file. --- ANSI.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ANSI.c b/ANSI.c index f81b5ae..c6f9e16 100644 --- a/ANSI.c +++ b/ANSI.c @@ -154,7 +154,8 @@ v1.80, 26 to 28 October, 2017: fix unloading; - revert back to (re)storing buffer cursor position. + revert back to (re)storing buffer cursor position; + increase cache to five handles. */ #include "ansicon.h" @@ -171,7 +172,7 @@ DWORD orgmode; // original mode CONSOLE_CURSOR_INFO orgcci; // original cursor state HANDLE hHeap; // local memory heap -#define CACHE 3 +#define CACHE 5 struct { HANDLE h;