_________ __ __
/ _____// |_____________ _/ |______ ____ __ __ ______
\_____ \\ __\_ __ \__ \\ __\__ \ / ___\| | \/ ___/
/ \| | | | \// __ \| | / __ \_/ /_/ > | /\___ \
/_______ /|__| |__| (____ /__| (____ /\___ /|____//____ >
\/ \/ \//_____/ \/
______________________ ______________________
T H E W A R B E G I N S
Stratagus - A free fantasy real time strategy game engine
#include <windows.h>#include <io.h>#include <fcntl.h>#include <stdio.h>Macros | |
| #define | _WIN32_WINNT_WIN2K 0x0500 |
Typedefs | |
| typedef int FAR WINAPI | proto_AttachConsole(int) |
| typedef int FAR WINAPI | proto_NtQueryObject(HANDLE, int, void *, unsigned long int, unsigned long int *) |
Functions | |
| static int | WINAPI_CheckIfConsoleHandle (HANDLE handle) |
| Check if HANDLE is attached to console. More... | |
| static void | WINAPI_ReopenFileFromHandle (HANDLE handle, FILE *file, const char *mode) |
| Try to reopen FILE* from WINAPI HANDLE. More... | |
| static void | WINAPI_SetStdHandleFromFile (int type, FILE *file) |
| Try to set std HANDLE from FILE*. More... | |
| static void | WINAPI_AttachConsole (void) |
| Try attach console of parent process for std input/output in Windows NT, 2000, XP or new. More... | |
| __attribute__ ((constructor)) static void initialize(void) | |
| This section set that WINAPI_AttachConsole() will be called at application startup before main() More... | |
Variables | |
| static int | fixmode = 0 |
| static HINSTANCE | lib_kernel32 = NULL |
| static HINSTANCE | lib_ntdll = NULL |
| static proto_AttachConsole * | func_AttachConsole = NULL |
| static proto_NtQueryObject * | func_NtQueryObject = NULL |
| #define _WIN32_WINNT_WIN2K 0x0500 |
| typedef int FAR WINAPI proto_AttachConsole(int) |
| typedef int FAR WINAPI proto_NtQueryObject(HANDLE, int, void *, unsigned long int, unsigned long int *) |
| __attribute__ | ( | (constructor) | ) |
This section set that WINAPI_AttachConsole() will be called at application startup before main()
|
static |
Try attach console of parent process for std input/output in Windows NT, 2000, XP or new.
|
static |
Check if HANDLE is attached to console.
|
static |
Try to reopen FILE* from WINAPI HANDLE.
|
static |
Try to set std HANDLE from FILE*.
|
static |
|
static |
|
static |
|
static |
|
static |
1.8.9.1
(C) Copyright 1998-2012 by The Stratagus Project under the GNU General Public License.