Author: cwittich Date: Mon Nov 19 15:14:54 2007 New Revision: 30577
URL: http://svn.reactos.org/svn/reactos?rev=30577&view=rev Log: don't crash when Buffer is NULL
Modified: trunk/reactos/lib/rtl/dos8dot3.c
Modified: trunk/reactos/lib/rtl/dos8dot3.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/lib/rtl/dos8dot3.c?rev=3057... ============================================================================== --- trunk/reactos/lib/rtl/dos8dot3.c (original) +++ trunk/reactos/lib/rtl/dos8dot3.c Mon Nov 19 15:14:54 2007 @@ -255,7 +255,7 @@ 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] == '.')