]> git.saurik.com Git - apple/libc.git/blob - string/FreeBSD/strcasecmp.3.patch
Libc-498.1.7.tar.gz
[apple/libc.git] / string / FreeBSD / strcasecmp.3.patch
1 --- _SB/Libc/string/FreeBSD/strcasecmp.3 2004-11-25 11:38:46.000000000 -0800
2 +++ _SB/Libc/string/FreeBSD/strcasecmp.3.edit 2006-06-28 16:55:53.000000000 -0700
3 @@ -39,16 +39,40 @@
4 .Os
5 .Sh NAME
6 .Nm strcasecmp ,
7 -.Nm strncasecmp
8 +.Nm strcasecmp_l ,
9 +.Nm strncasecmp ,
10 +.Nm strncasecmp_l
11 .Nd compare strings, ignoring case
12 .Sh LIBRARY
13 .Lb libc
14 .Sh SYNOPSIS
15 .In strings.h
16 .Ft int
17 -.Fn strcasecmp "const char *s1" "const char *s2"
18 +.Fo strcasecmp
19 +.Fa "const char *s1"
20 +.Fa "const char *s2"
21 +.Fc
22 .Ft int
23 -.Fn strncasecmp "const char *s1" "const char *s2" "size_t len"
24 +.Fo strncasecmp
25 +.Fa "const char *s1"
26 +.Fa "const char *s2"
27 +.Fa "size_t n"
28 +.Fc
29 +.In strings.h
30 +.In xlocale.h
31 +.Ft int
32 +.Fo strcasecmp_l
33 +.Fa "const char *s1"
34 +.Fa "const char *s2"
35 +.Fa "locale_t loc"
36 +.Fc
37 +.Ft int
38 +.Fo strncasecmp_l
39 +.Fa "const char *s1"
40 +.Fa "const char *s2"
41 +.Fa "size_t n"
42 +.Fa "locale_t loc"
43 +.Fc
44 .Sh DESCRIPTION
45 The
46 .Fn strcasecmp
47 @@ -63,8 +87,20 @@
48 The
49 .Fn strncasecmp
50 compares at most
51 -.Fa len
52 +.Fa n
53 characters.
54 +.Pp
55 +Although the
56 +.Fn strcasecmp
57 +and
58 +.Fn strncasecmp
59 +functions use the current locale, the
60 +.Fn strcasecmp_l
61 +and
62 +.Fn strncasecmp_l
63 +functions may be passed locales directly. See
64 +.Xr xlocale 3
65 +for more information.
66 .Sh RETURN VALUES
67 The
68 .Fn strcasecmp
69 @@ -87,7 +123,8 @@
70 .Xr strcmp 3 ,
71 .Xr strcoll 3 ,
72 .Xr strxfrm 3 ,
73 -.Xr tolower 3
74 +.Xr tolower 3 ,
75 +.Xr xlocale 3
76 .Sh HISTORY
77 The
78 .Fn strcasecmp