trying to fix some bugs.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@998 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2005-05-08 06:02:03 +00:00
parent 90ffea325d
commit 76f5eb5769

View file

@ -201,8 +201,11 @@ void VARGS Sys_DebugLog(char *file, char *fmt, ...)
}
#endif
fd = fopen(file, "ab");
fprintf(fd, "%s", data);
fclose(fd);
if (fd)
{
fprintf(fd, "%s", data);
fclose(fd);
}
};
int *debug;
@ -751,6 +754,9 @@ char *Sys_ConsoleInput (void)
HANDLE th;
char *clipText, *textCopied;
if (!hinput)
return;
for ( ;; )
{
if (!GetNumberOfConsoleInputEvents (hinput, &numevents))
@ -868,6 +874,9 @@ qboolean Sys_InitTerminal (void)
void Sys_CloseTerminal (void)
{
FreeConsole();
hinput = NULL;
houtput = NULL;
}
@ -883,7 +892,7 @@ void Sys_SendKeyEvents (void)
{
MSG msg;
if (!qrenderer)
if (isDedicated)
{
#ifndef CLIENTONLY
SV_GetConsoleCommands ();