msvcr: Add _getch_nolock implementation.
This commit is contained in:
parent
d0cb2519b6
commit
3bd60974a9
|
@ -890,7 +890,7 @@
|
|||
@ cdecl _get_wpgmptr(ptr)
|
||||
@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock
|
||||
@ cdecl _getch()
|
||||
@ stub _getch_nolock
|
||||
@ cdecl _getch_nolock()
|
||||
@ cdecl _getche()
|
||||
@ stub _getche_nolock
|
||||
@ cdecl _getcwd(str long) MSVCRT__getcwd
|
||||
|
|
|
@ -1238,7 +1238,7 @@
|
|||
@ cdecl _get_wpgmptr(ptr)
|
||||
@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock
|
||||
@ cdecl _getch()
|
||||
@ stub _getch_nolock
|
||||
@ cdecl _getch_nolock()
|
||||
@ cdecl _getche()
|
||||
@ stub _getche_nolock
|
||||
@ cdecl _getcwd(str long) MSVCRT__getcwd
|
||||
|
|
|
@ -1236,7 +1236,7 @@
|
|||
@ cdecl _get_wpgmptr(ptr)
|
||||
@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock
|
||||
@ cdecl _getch()
|
||||
@ stub _getch_nolock
|
||||
@ cdecl _getch_nolock()
|
||||
@ cdecl _getche()
|
||||
@ stub _getche_nolock
|
||||
@ cdecl _getcwd(str long) MSVCRT__getcwd
|
||||
|
|
|
@ -564,7 +564,7 @@
|
|||
@ cdecl _get_wpgmptr(ptr)
|
||||
@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock
|
||||
@ cdecl _getch()
|
||||
@ stub _getch_nolock
|
||||
@ cdecl _getch_nolock()
|
||||
@ cdecl _getche()
|
||||
@ stub _getche_nolock
|
||||
@ cdecl _getcwd(str long) MSVCRT__getcwd
|
||||
|
|
|
@ -541,7 +541,7 @@
|
|||
@ cdecl _get_wpgmptr(ptr)
|
||||
@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock
|
||||
@ cdecl _getch()
|
||||
@ stub _getch_nolock
|
||||
@ cdecl _getch_nolock()
|
||||
@ cdecl _getche()
|
||||
@ stub _getche_nolock
|
||||
@ cdecl _getcwd(str long) MSVCRT__getcwd
|
||||
|
|
|
@ -113,13 +113,12 @@ static const struct {unsigned vk; unsigned ch[4][2];} enh_map[] = {
|
|||
};
|
||||
|
||||
/*********************************************************************
|
||||
* _getch (MSVCRT.@)
|
||||
* _getch_nolock (MSVCR80.@)
|
||||
*/
|
||||
int CDECL _getch(void)
|
||||
int CDECL _getch_nolock(void)
|
||||
{
|
||||
int retval = MSVCRT_EOF;
|
||||
|
||||
LOCK_CONSOLE;
|
||||
if (__MSVCRT_console_buffer != MSVCRT_EOF)
|
||||
{
|
||||
retval = __MSVCRT_console_buffer;
|
||||
|
@ -179,10 +178,22 @@ int CDECL _getch(void)
|
|||
if (mode)
|
||||
SetConsoleMode(MSVCRT_console_in, mode);
|
||||
}
|
||||
UNLOCK_CONSOLE;
|
||||
return retval;
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* _getch (MSVCRT.@)
|
||||
*/
|
||||
int CDECL _getch(void)
|
||||
{
|
||||
int ret;
|
||||
|
||||
LOCK_CONSOLE;
|
||||
ret = _getch_nolock();
|
||||
UNLOCK_CONSOLE;
|
||||
return ret;
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* _putch (MSVCRT.@)
|
||||
*/
|
||||
|
|
Loading…
Reference in New Issue