"Eric Pouech" pouech-eric@wanadoo.fr wrote:
+HANDLE WINAPI OpenConsoleW(LPCWSTR name, DWORD access, LPSECURITY_ATTRIBUTES sa,
DWORD creation)
+{
- static const WCHAR coninW[] = {'C','O','N','I','N','$',0};
- static const WCHAR conoutW[] = {'C','O','N','O','U','T','$',0};
- BOOL output;
- HANDLE ret;
- if (strcmpW(coninW, name) == 0)
output = FALSE;
- else if (strcmpW(conoutW, name) == 0)
output = TRUE;
While you are moving the code around then you are probably reviewing it as well? So, the question is: shouldn't the above comparisons be case insensitive?