unicode build fixes
authorSylvain Petreolle <spetreolle@yahoo.fr>
Mon, 11 Dec 2006 18:04:02 +0000 (18:04 +0000)
committerSylvain Petreolle <spetreolle@yahoo.fr>
Mon, 11 Dec 2006 18:04:02 +0000 (18:04 +0000)
svn path=/trunk/; revision=25126

reactos/base/shell/cmd/console.c
reactos/base/shell/cmd/start.c

index 134d296..6a0ae7a 100644 (file)
@@ -238,7 +238,7 @@ VOID ConPrintf(LPTSTR szFormat, va_list arg_ptr, DWORD nStdHandle)
 INT ConPrintfPaging(BOOL NewPage, LPTSTR szFormat, va_list arg_ptr, DWORD nStdHandle)
 {
        INT len;
-       PCHAR pBuf;
+       PTCHAR pBuf;
        CONSOLE_SCREEN_BUFFER_INFO csbi;
        TCHAR szOut[OUTPUT_BUFFER_SIZE];
        DWORD dwWritten;
@@ -284,12 +284,7 @@ INT ConPrintfPaging(BOOL NewPage, LPTSTR szFormat, va_list arg_ptr, DWORD nStdHa
         }
  
        len = _vstprintf (szOut, szFormat, arg_ptr);
-#ifdef _UNICODE
-       pBuf = malloc(len + 1);
-       len = WideCharToMultiByte( OutputCodePage, 0, szOut, len + 1, pBuf, len + 1, NULL, NULL) - 1;
-#else
        pBuf = szOut;
-#endif
  
        for(i = 0; i < len; i++)
        { 
index b6195d0..55d1480 100644 (file)
@@ -50,27 +50,27 @@ INT cmd_start (LPTSTR First, LPTSTR Rest)
                        ConOutResPaging(TRUE,STRING_START_HELP1);
                        return 0;
                }
-               else if(!_tcsicmp(arg[i], "/LOW"))
+               else if(!_tcsicmp(arg[i], _T("/LOW")))
                {
                        Priority = IDLE_PRIORITY_CLASS;         
                }
-               else if(!_tcsicmp(arg[i], "/NORMAL"))
+               else if(!_tcsicmp(arg[i], _T("/NORMAL")))
                {
                        Priority = NORMAL_PRIORITY_CLASS;
                }
-               else if(!_tcsicmp(arg[i], "/HIGH"))
+               else if(!_tcsicmp(arg[i], _T("/HIGH")))
                {
                        Priority = HIGH_PRIORITY_CLASS;         
                }
-               else if(!_tcsicmp(arg[i], "/REALTIME"))
+               else if(!_tcsicmp(arg[i], _T("/REALTIME")))
                {
                        Priority = REALTIME_PRIORITY_CLASS;
                }
-               else if(!_tcsicmp(arg[i], "/ABOVENORMAL"))
+               else if(!_tcsicmp(arg[i], _T("/ABOVENORMAL")))
                {
                        Priority = ABOVE_NORMAL_PRIORITY_CLASS;         
                }
-               else if(!_tcsicmp(arg[i], "/BELOWNORMAL"))
+               else if(!_tcsicmp(arg[i], _T("/BELOWNORMAL")))
                {
                        Priority = BELOW_NORMAL_PRIORITY_CLASS;
                }