mirror of
https://github.com/reactos/reactos.git
synced 2024-10-15 05:37:44 +00:00
- Fix to allow characters for computer name as specified in MSDN, even '-'
- See issue #3304 for more details. svn path=/trunk/; revision=34275
This commit is contained in:
parent
8e5bf80622
commit
0dd1a22450
|
@ -298,22 +298,10 @@ IsValidComputerName (
|
|||
p = (PWCHAR)lpComputerName;
|
||||
while (*p != 0)
|
||||
{
|
||||
if ((!iswctype (*p, _ALPHA) && !iswctype (*p, _DIGIT)) ||
|
||||
*p == L'!' ||
|
||||
*p == L'@' ||
|
||||
*p == L'#' ||
|
||||
*p == L'$' ||
|
||||
*p == L'%' ||
|
||||
*p == L'^' ||
|
||||
*p == L'&' ||
|
||||
*p == L'\'' ||
|
||||
*p == L')' ||
|
||||
*p == L'(' ||
|
||||
*p == L'.' ||
|
||||
*p == L'_' ||
|
||||
*p == L'{' ||
|
||||
*p == L'}' ||
|
||||
*p == L'~')
|
||||
if (!(iswalnum(*p) || *p == L'!' || *p == L'@' || *p == L'#' ||
|
||||
*p == L'$' || *p == L'%' || *p == L'^' || *p == L'&' || *p == L'\'' ||
|
||||
*p == L')' || *p == L'(' || *p == L'.' || *p == L'-' || *p == L'_' ||
|
||||
*p == L'{' || *p == L'}' || *p == L'~'))
|
||||
return FALSE;
|
||||
|
||||
Length++;
|
||||
|
|
Loading…
Reference in a new issue