mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
parent
a5ab0faee7
commit
8f291ce528
|
@ -170,6 +170,15 @@ static void logger_file(const char *line, void *user)
|
|||
aio_unlock(logfile);
|
||||
}
|
||||
|
||||
#if defined(CONF_FAMILY_WINDOWS)
|
||||
static void logger_stdout_sync(const char *line, void *user)
|
||||
{
|
||||
(void)user;
|
||||
puts(line);
|
||||
fflush(stdout);
|
||||
}
|
||||
#endif
|
||||
|
||||
static void logger_stdout_finish(void *user)
|
||||
{
|
||||
ASYNCIO *logfile = (ASYNCIO *)user;
|
||||
|
@ -212,7 +221,11 @@ void dbg_logger(DBG_LOGGER logger, DBG_LOGGER_FINISH finish, void *user)
|
|||
|
||||
void dbg_logger_stdout()
|
||||
{
|
||||
#if defined(CONF_FAMILY_WINDOWS)
|
||||
dbg_logger(logger_stdout_sync, 0, 0);
|
||||
#else
|
||||
dbg_logger(logger_file, logger_stdout_finish, aio_new(io_stdout()));
|
||||
#endif
|
||||
}
|
||||
|
||||
void dbg_logger_debugger()
|
||||
|
|
Loading…
Reference in a new issue