]> git.ipfire.org Git - thirdparty/man-pages.git/blobdiff - man3/catopen.3
fuse.4: ffix
[thirdparty/man-pages.git] / man3 / catopen.3
index 7ddd7d3be820015c7f944897292836636f75b7c9..f005d70024b85ece41b95dc6eeb0adf93f95fbad 100644 (file)
@@ -1,6 +1,6 @@
 .\" Copyright 1993 Mitchum DSouza <m.dsouza@mrc-applied-psychology.cambridge.ac.uk>
 .\"
-.\" %%%LICENSE_START(verbatim)
+.\" %%%LICENSE_START(VERBATIM)
 .\" Permission is granted to make and distribute verbatim copies of this
 .\" manual provided the copyright notice and this permission notice are
 .\" preserved on all copies.
 .\" Modified Thu Dec 13 22:51:19 2001 by Martin Schulze <joey@infodrom.org>
 .\" Modified 2001-12-14 aeb
 .\"
-.TH CATOPEN 3 2001-12-14 "GNU" "Linux Programmer's Manual"
+.TH CATOPEN 3 2015-08-08 "GNU" "Linux Programmer's Manual"
 .SH NAME
 catopen, catclose \- open/close a message catalog
 .SH SYNOPSIS
 .B #include <nl_types.h>
-.sp
+.PP
 .BI "nl_catd catopen(const char *" name ", int " flag );
-
+.PP
 .BI "int catclose(nl_catd " catalog );
 .SH DESCRIPTION
 The function
@@ -42,17 +42,17 @@ The descriptor remains valid until
 .BR catclose ()
 or
 .BR execve (2).
-If a file descriptor is used to implement catalog descriptors
+If a file descriptor is used to implement catalog descriptors,
 then the
 .B FD_CLOEXEC
 flag will be set.
-.LP
+.PP
 The argument
 .I name
 specifies the name of the message catalog to be opened.
 If
 .I name
-specifies and absolute path (i.e., contains a \(aq/\(aq),
+specifies an absolute path (i.e., contains a \(aq/\(aq),
 then
 .I name
 specifies a pathname for the message catalog.
@@ -88,20 +88,20 @@ Changing the
 .B LC_MESSAGES
 part of the locale may invalidate
 open catalog descriptors.
-.LP
+.PP
 The
 .I flag
 argument to
 .BR catopen ()
 is used to indicate the source for the language to use.
 If it is set to
-.B NL_CAT_LOCALE
+.BR NL_CAT_LOCALE ,
 then it will use the current locale setting for
 .BR LC_MESSAGES .
-Otherwise it will use the
+Otherwise, it will use the
 .B LANG
 environment variable.
-.LP
+.PP
 The function
 .BR catclose ()
 closes the message catalog identified by
@@ -115,7 +115,8 @@ The function
 returns a message catalog descriptor of type
 .I nl_catd
 on success.
-On failure, it returns \fI(nl_catd)\ \-1\fP
+On failure, it returns
+.IR "(nl_catd)\ \-1"
 and sets
 .I errno
 to indicate the error.
@@ -123,7 +124,7 @@ The possible error values include all
 possible values for the
 .BR open (2)
 call.
-.LP
+.PP
 The function
 .BR catclose ()
 returns 0 on success, or \-1 on failure.
@@ -142,50 +143,66 @@ is set to
 The language to use if
 .I flag
 is 0.
+.SH ATTRIBUTES
+For an explanation of the terms used in this section, see
+.BR attributes (7).
+.TS
+allbox;
+lb lb lb
+l l l.
+Interface      Attribute       Value
+T{
+.BR catopen ()
+T}     Thread safety   MT-Safe env
+T{
+.BR catclose ()
+T}     Thread safety   MT-Safe
+.TE
 .SH CONFORMING TO
-POSIX.1-2001.
+POSIX.1-2001, POSIX.1-2008.
 .\" In XPG 1987, Vol. 3 it says:
 .\" .I "The flag argument of catopen is reserved for future use"
 .\" .IR "and should be set to 0" .
-It is unclear what the source was for the constants
-.B MCLoadBySet
-and
-.B MCLoadAll
-(see below).
+.\"
+.\" It is unclear what the source was for the constants
+.\" .B MCLoadBySet
+.\" and
+.\" .B MCLoadAll
+.\" (see below).
 .SH NOTES
-The above is the POSIX.1-2001 description.
+The above is the POSIX.1 description.
 The glibc value for
 .B NL_CAT_LOCALE
 is 1.
-(Compare
-.B MCLoadAll
-below.)
+.\" (Compare
+.\" .B MCLoadAll
+.\" below.)
 The default path varies, but usually looks at a number of places below
 .IR /usr/share/locale .
-.SS Linux notes
-These functions are available for Linux since libc 4.4.4c.
-In the case of linux libc4 and libc5, the catalog descriptor
-.I nl_catd
-is a
-.BR mmap (2)'ed
-area of memory and not a file descriptor.
-The
-.I flag
-argument to
-.BR catopen ()
-should be either
-.B MCLoadBySet
-(=0) or
-.B MCLoadAll
-(=1).
-The former value indicates that a set from the catalog is to be
-loaded when needed, whereas the latter causes the initial call to
-.BR catopen ()
-to load the entire catalog into memory.
-The default search path varies, but usually looks at a number of places below
-.I /etc/locale
-and
-.IR /usr/lib/locale .
+.\" .SS Linux notes
+.\" These functions are available for Linux since libc 4.4.4c.
+.\" In the case of linux libc4 and libc5, the catalog descriptor
+.\" .I nl_catd
+.\" is a
+.\" .BR mmap (2)'ed
+.\" area of memory and not a file descriptor.
+.\" The
+.\" .I flag
+.\" argument to
+.\" .BR catopen ()
+.\" should be either
+.\" .B MCLoadBySet
+.\" (=0) or
+.\" .B MCLoadAll
+.\" (=1).
+.\" The former value indicates that a set from the catalog is to be
+.\" loaded when needed, whereas the latter causes the initial call to
+.\" .BR catopen ()
+.\" to load the entire catalog into memory.
+.\" The default search path varies, but usually looks at a number of places below
+.\" .I /etc/locale
+.\" and
+.\" .IR /usr/lib/locale .
 .SH SEE ALSO
 .BR catgets (3),
 .BR setlocale (3)