]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
added int cast on write call in new terminal printing code, and added an include...
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 23 Feb 2006 05:43:57 +0000 (05:43 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 23 Feb 2006 05:43:57 +0000 (05:43 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@6011 d7cf8633-e32d-0410-b094-e92efae38249

sys_linux.c
sys_sdl.c

index 13bc04f4ecee5a0fbbdead531fb518c15c1c08da..d0120432b6f745981916d8416bb817dd8e4ff829 100644 (file)
@@ -1,5 +1,6 @@
 
 #ifdef WIN32
 
 #ifdef WIN32
+#include <io.h>
 #include "conio.h"
 #else
 #include <unistd.h>
 #include "conio.h"
 #else
 #include <unistd.h>
@@ -58,7 +59,7 @@ void Sys_PrintToTerminal(const char *text)
 #endif
        while(*text)
        {
 #endif
        while(*text)
        {
-               ssize_t written = write(1, text, strlen(text));
+               int written = (int)write(1, text, strlen(text));
                if(written <= 0)
                        break; // sorry, I cannot do anything about this error - without an output
                text += written;
                if(written <= 0)
                        break; // sorry, I cannot do anything about this error - without an output
                text += written;
index 3833fdad9308fec02e1e6d0419fd78f077205a35..d18b4b6e18d24dafe8226647e967827d19a2e559 100644 (file)
--- a/sys_sdl.c
+++ b/sys_sdl.c
@@ -1,5 +1,6 @@
 
 #ifdef WIN32
 
 #ifdef WIN32
+#include <io.h>
 #include "conio.h"
 #else
 #include <unistd.h>
 #include "conio.h"
 #else
 #include <unistd.h>
@@ -56,7 +57,7 @@ void Sys_PrintToTerminal(const char *text)
 #endif
        while(*text)
        {
 #endif
        while(*text)
        {
-               ssize_t written = write(1, text, strlen(text));
+               int written = (int)write(1, text, strlen(text));
                if(written <= 0)
                        break; // sorry, I cannot do anything about this error - without an output
                text += written;
                if(written <= 0)
                        break; // sorry, I cannot do anything about this error - without an output
                text += written;