Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libc/gen document utmpxname(3)
details: https://anonhg.NetBSD.org/src/rev/16864a882d14
branches: trunk
changeset: 973596:16864a882d14
user: christos <christos%NetBSD.org@localhost>
date: Sun Jul 05 01:05:50 2020 +0000
description:
document utmpxname(3)
diffstat:
lib/libc/gen/Makefile.inc | 4 ++--
lib/libc/gen/endutxent.3 | 32 +++++++++++++++++++++++++-------
2 files changed, 27 insertions(+), 9 deletions(-)
diffs (106 lines):
diff -r 858d2c479d40 -r 16864a882d14 lib/libc/gen/Makefile.inc
--- a/lib/libc/gen/Makefile.inc Sun Jul 05 01:05:01 2020 +0000
+++ b/lib/libc/gen/Makefile.inc Sun Jul 05 01:05:50 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.203 2020/05/10 19:36:49 maya Exp $
+# $NetBSD: Makefile.inc,v 1.204 2020/07/05 01:05:50 christos Exp $
# from: @(#)Makefile.inc 8.6 (Berkeley) 5/4/95
# gen sources
@@ -97,7 +97,7 @@
directory.3 fdopendir.3
MLINKS+=endutxent.3 getutxent.3 endutxent.3 getutxid.3 \
endutxent.3 getutxline.3 endutxent.3 pututxline.3 \
- endutxent.3 setutxent.3
+ endutxent.3 setutxent.3 endutmpx.3 utmpxname.3
MLINKS+=err.3 verr.3 err.3 errx.3 err.3 verrx.3 err.3 warn.3 err.3 vwarn.3 \
err.3 warnx.3 err.3 vwarnx.3 err.3 errc.3 err.3 verrc.3 err.3 warnc.3 \
err.3 vwarnc.3
diff -r 858d2c479d40 -r 16864a882d14 lib/libc/gen/endutxent.3
--- a/lib/libc/gen/endutxent.3 Sun Jul 05 01:05:01 2020 +0000
+++ b/lib/libc/gen/endutxent.3 Sun Jul 05 01:05:50 2020 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: endutxent.3,v 1.5 2008/04/30 13:10:50 martin Exp $
+.\" $NetBSD: endutxent.3,v 1.6 2020/07/05 01:05:50 christos Exp $
.\"
.\" Copyright (c) 2002 The NetBSD Foundation, Inc.
.\" All rights reserved.
@@ -27,7 +27,7 @@
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
-.Dd September 26, 2002
+.Dd July 4, 2020
.Dt ENDUTXENT 3
.Os
.Sh NAME
@@ -36,7 +36,8 @@
.Nm getutxid ,
.Nm getutxline ,
.Nm pututxline ,
-.Nm setutxent
+.Nm setutxent ,
+.Nm utxname
.Nd user accounting database functions
.Sh LIBRARY
.Lb libc
@@ -47,13 +48,15 @@
.Ft struct utmpx *
.Fn getutxent void
.Ft struct utmpx *
-.Fn getutxid "const struct utmpx *"
+.Fn getutxid "const struct utmpx *ut"
.Ft struct utmpx *
-.Fn getutxline "const struct utmpx *"
+.Fn getutxline "const struct utmpx *ut"
.Ft struct utmpx *
-.Fn pututxline "const struct utmpx *"
+.Fn pututxline "const struct utmpx *ut"
.Ft void
.Fn setutxent void
+.Ft void
+.Fn utmpxname "const char *fname"
.Sh DESCRIPTION
These functions provide access to the
.Xr utmpx 5
@@ -91,6 +94,10 @@
.Xr utmpx 5
entry line to the accounting database, replacing a previous entry for
the same user if it exists.
+.Pp
+.Fn utmpxname
+set sets the database file to
+.Fa fname .
.Ss The utmpx structure
The
.Nm utmpx
@@ -155,6 +162,12 @@
.Fn pututxline
returns the structure that was successfully written, or
.Dv NULL .
+.Fn utmpxname
+returns
+.Dv 1
+on success and
+.Dv 0
+on failure.
.Sh SEE ALSO
.Xr logwtmpx 3 ,
.Xr utmpx 5
@@ -166,10 +179,15 @@
.Fn getutxline ,
.Fn pututxline ,
.Fn setutxent
-all conform to
+functions all conform to
.St -p1003.1-2001
(XSI extension), and previously to
.St -xpg4.2 .
+The
+.Fn utxname
+functions is a
+.Nx
+externsion.
The fields
.Fa ut_user ,
.Fa ut_id ,
Home |
Main Index |
Thread Index |
Old Index