]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - sys_win.c
honor alpha in showsurfaces 3
[xonotic/darkplaces.git] / sys_win.c
index 5431221a12d0848455ab2614b45fd8a100577993..ee6ef061c219b4204a388f0cd41c62f32c44a2d0 100644 (file)
--- a/sys_win.c
+++ b/sys_win.c
@@ -269,7 +269,7 @@ char *Sys_ConsoleInput (void)
                                                break;
 
                                        default:
-                                               if (ch >= ' ')
+                                               if (ch >= (int) (unsigned char) ' ')
                                                {
                                                        WriteFile(houtput, &ch, 1, &dummy, NULL);
                                                        text[len] = ch;
@@ -423,7 +423,7 @@ int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLin
        // FIXME: this tokenizer is rather redundent, call a more general one
        while (*lpCmdLine && (com_argc < MAX_NUM_ARGVS))
        {
-               while (*lpCmdLine && *lpCmdLine <= ' ')
+               while (*lpCmdLine && ISWHITESPACE(*lpCmdLine))
                        lpCmdLine++;
 
                if (!*lpCmdLine)
@@ -443,7 +443,7 @@ int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLin
                        // unquoted word
                        argv[com_argc] = lpCmdLine;
                        com_argc++;
-                       while (*lpCmdLine && *lpCmdLine > ' ')
+                       while (*lpCmdLine && !ISWHITESPACE(*lpCmdLine))
                                lpCmdLine++;
                }
 
@@ -460,6 +460,8 @@ int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLin
        return true;
 }
 
+#if 0
+// unused, this file is only used when building windows client and vid_wgl provides WinMain() instead
 int main (int argc, const char* argv[])
 {
        MEMORYSTATUS lpBuffer;
@@ -479,3 +481,5 @@ int main (int argc, const char* argv[])
 
        return true;
 }
+#endif
+