Mercurial > repos > blastem
view terminal_win.c @ 2096:460c93c19146
Fix CDD byte cycle counter deduction that got broken when I fixed the off-by-one on CD-DA
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Mon, 07 Feb 2022 21:54:57 -0800 |
parents | 0433fdd9ba66 |
children |
line wrap: on
line source
#include <windows.h> #include <stdio.h> static char init_done; void force_no_terminal() { init_done = 1; } void init_terminal() { if (!init_done) { AllocConsole(); freopen("CONIN$", "r", stdin); freopen("CONOUT$", "w", stdout); freopen("CONOUT$", "w", stderr); init_done = 1; } }