]> sourceware.org Git - newlib-cygwin.git/commitdiff
Cygwin: console: Fix a bug that cannot handle consoles more than 32.
authorTakashi Yano <takashi.yano@nifty.ne.jp>
Thu, 15 Feb 2024 17:37:46 +0000 (02:37 +0900)
committerTakashi Yano <takashi.yano@nifty.ne.jp>
Thu, 15 Feb 2024 17:37:46 +0000 (02:37 +0900)
Fixes: 3721a756b0d8 ("Cygwin: console: Make the console accessible from other terminals.")
Signed-off-by: Takashi Yano <takashi.yano@nifty.ne.jp>
winsup/cygwin/devices.cc
winsup/cygwin/devices.in
winsup/cygwin/release/3.5.1

index b14613bc7363d98ae526f85893bec3f286f8cd84..5b67fd1dad7aec26696f755f1b474930a16d25e4 100644 (file)
@@ -84,7 +84,7 @@ exists_console (const device& dev)
       if (dev.get_minor () < MAX_CONS_DEV)
        {
          unsigned long bitmask = fhandler_console::console_unit (-1);
-         return bitmask & (1UL << dev.get_minor ());
+         return !!(bitmask & (1UL << dev.get_minor ()));
        }
       return false;
     }
index e15a35f251b1f2202d82e76b0febe48641fc9899..be54346fbe2ce6bc94cfed4473652c6209dd0774 100644 (file)
@@ -80,7 +80,7 @@ exists_console (const device& dev)
       if (dev.get_minor () < MAX_CONS_DEV)
        {
          unsigned long bitmask = fhandler_console::console_unit (-1);
-         return bitmask & (1UL << dev.get_minor ());
+         return !!(bitmask & (1UL << dev.get_minor ()));
        }
       return false;
     }
index e041f98f3862ab324f0ab16e0a20bbbeea89841e..96d2ad32fa79d7e764dd03d8ff0ab029bc44c85d 100644 (file)
@@ -18,3 +18,5 @@ Fixes:
   Addresses: https://github.com/msys2/msys2-runtime/issues/198
 
 - Fix the problem that VMIN and VTIME does not work at all in console.
+
+- Fix a bug that cannot handle consoles more than 32, rather than 64.
This page took 0.042723 seconds and 5 git commands to generate.