12 #include "darkplaces.h"
16 // =======================================================================
18 // =======================================================================
19 void Sys_Shutdown (void)
22 fcntl (0, F_SETFL, fcntl (0, F_GETFL, 0) & ~O_NONBLOCK);
27 void Sys_SDL_Dialog(const char *title, const char *string)
31 void Sys_Print(const char *text)
35 // BUG: for some reason, NDELAY also affects stdout (1) when used on stdin (0).
36 // this is because both go to /dev/tty by default!
39 int origflags = fcntl (sys.outfd, F_GETFL, 0);
40 fcntl (sys.outfd, F_SETFL, origflags & ~O_NONBLOCK);
46 fs_offset_t written = (fs_offset_t)write(sys.outfd, text, (int)strlen(text));
48 break; // sorry, I cannot do anything about this error - without an output
52 fcntl (sys.outfd, F_SETFL, origflags);
55 //fprintf(stdout, "%s", text);
58 char *Sys_GetClipboardData (void)
63 void Sys_SDL_Init(void)
67 qbool sys_supportsdlgetticks = false;
68 unsigned int Sys_SDL_GetTicks (void)
70 Sys_Error("Called Sys_SDL_GetTicks on non-SDL target");
73 void Sys_SDL_Delay (unsigned int milliseconds)
75 Sys_Error("Called Sys_SDL_Delay on non-SDL target");