Added two checks for out of range pointer accesses.
[wine/multimedia.git] / misc / lstr.c
blob5e2e87d2483ee3bf9bb50bcff249e0e405d272d3
1 /*
2 * String functions
4 * Copyright 1993 Yngvi Sigurjonsson (yngvi@hafro.is)
5 * Copyright 1996 Marcus Meissner
6 */
8 #include "config.h"
10 #include <stdarg.h>
11 #include <stdlib.h>
12 #include <stdio.h>
13 #include <string.h>
14 #include <ctype.h>
16 #include "windef.h"
17 #include "winbase.h"
18 #include "wingdi.h"
19 #include "winuser.h"
20 #include "wine/winbase16.h"
21 #include "wine/winuser16.h"
22 #include "wine/unicode.h"
23 #include "winnls.h"
24 #include "heap.h"
25 #include "ldt.h"
26 #include "debugtools.h"
28 DEFAULT_DEBUG_CHANNEL(resource);
30 extern const WORD OLE2NLS_CT_CType3_LUT[]; /* FIXME: does not belong here */
32 /***********************************************************************
33 * IsCharAlphaA (USER.433) (USER32.331)
34 * FIXME: handle current locale
36 BOOL WINAPI IsCharAlphaA(CHAR x)
38 return (OLE2NLS_CT_CType3_LUT[(unsigned char)x] & C3_ALPHA);
41 /***********************************************************************
42 * IsCharAlphaNumericA (USER.434) (USER32.332)
43 * FIXME: handle current locale
45 BOOL WINAPI IsCharAlphaNumericA(CHAR x)
47 return IsCharAlphaA(x) || isdigit(x) ;