don't crash when Buffer is NULL

svn path=/trunk/; revision=30577
This commit is contained in:
Christoph von Wittich 2007-11-19 12:14:54 +00:00
parent 735f6dcf69
commit 17095a0c94

View file

@ -255,7 +255,7 @@ RtlIsNameLegalDOS8Dot3(IN PCUNICODE_STRING UnicodeName,
if (RtlUpcaseUnicodeStringToCountedOemString( AnsiName, UnicodeName, FALSE ) != STATUS_SUCCESS)
return FALSE;
if (AnsiName->Length > 12) return FALSE;
if ((AnsiName->Length > 12) || (AnsiName->Buffer == NULL)) return FALSE;
/* a starting . is invalid, except for . and .. */
if (AnsiName->Buffer[0] == '.')