OSDN Git Service

Update README
[linuxjm/LDP_man-pages.git] / draft / man3 / updwtmp.3
1 .\" Copyright 1997 Nicolás Lichtmaier <nick@debian.org>
2 .\" Created Wed Jul  2 23:27:34 ART 1997
3 .\"
4 .\" %%%LICENSE_START(GPLv2+_DOC_FULL)
5 .\" This is free documentation; you can redistribute it and/or
6 .\" modify it under the terms of the GNU General Public License as
7 .\" published by the Free Software Foundation; either version 2 of
8 .\" the License, or (at your option) any later version.
9 .\"
10 .\" The GNU General Public License's references to "object code"
11 .\" and "executables" are to be interpreted as the output of any
12 .\" document formatting or typesetting system, including
13 .\" intermediate and printed output.
14 .\"
15 .\" This manual is distributed in the hope that it will be useful,
16 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
17 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 .\" GNU General Public License for more details.
19 .\"
20 .\" You should have received a copy of the GNU General Public
21 .\" License along with this manual; if not, see
22 .\" <http://www.gnu.org/licenses/>.
23 .\" %%%LICENSE_END
24 .\"
25 .\" Added info on availability, aeb, 971207
26 .\" Added -lutil remark, 030718
27 .\" 2008-07-02, mtk, document updwtmpx()
28 .\"
29 .\"*******************************************************************
30 .\"
31 .\" This file was generated with po4a. Translate the source file.
32 .\"
33 .\"*******************************************************************
34 .\"
35 .\" Japanese Version Copyright (c) 1998 Tomoyuki NISHIOKA
36 .\"         all rights reserved.
37 .\" Translated Sat May 23 18:46:34 JST 1998
38 .\"         by Tomoyuki NISHIOKA <nishioka@a.tsukuba-tech.ac.jp>
39 .\" Updated 2003-09-14 by Kentaro Shirakata <argrath@ub32.org>
40 .\" Updated 2008-07-30 by Kentaro Shirakata <argrath@ub32.org>
41 .\"
42 .TH UPDWTMP 3 2014\-08\-19 GNU "Linux Programmer's Manual"
43 .SH 名前
44 updwtmp, logwtmp \- wtmp ファイルにエントリーを追加する
45 .SH 書式
46 .nf
47 \fB#include <utmp.h>\fP
48 .sp
49 \fBvoid updwtmp(const char *\fP\fIwtmp_file\fP\fB, const struct utmp *\fP\fIut\fP\fB);\fP
50 .br
51 \fBvoid logwtmp(const char *\fP\fIline\fP\fB, const char *\fP\fIname\fP\fB, const char *\fP\fIhost\fP\fB);\fP
52 .fi
53
54 \fBlogwtmp\fP() は \fI\-lutil\fP でリンクする。
55 .SH 説明
56 \fBupdwtmp\fP()  は、utmp 構造体 \fIut\fP を wtmp ファイルに追加する。
57 .PP
58 \fBlogwtmp\fP()  は、 \fIline\fP, \fIname\fP, \fIhost\fP, 現在時刻、現プロセスID から utmp 構造体を作り、
59 \fBupdwtmp\fP()  を呼び出してその構造体を wtmp ファイルに追加する。
60 .SH ファイル
61 .TP 
62 \fI/var/log/wtmp\fP
63 ユーザーログインの履歴データベース
64 .SH 準拠
65 POSIX.1\-2001 にはない。 Solaris, NetBSD に存在し、おそらく他のシステムにもあるだろう。
66 .SH 注意
67 他の "utmpx" 関数群 (\fBgetutxent\fP(3)  参照) との一貫性のために、glibc (バージョン 2.1 以降) は以下の関数を
68 提供している:
69 .nf
70 .sp
71 \fB#include <utmpx.h>\fP
72 .sp
73 \fBvoid updwtmpx (const char *\fP\fIwtmpx_file\fP\fB, const struct utmpx *\fP\fIutx\fP\fB);\fP
74 .fi
75 .PP
76 この関数は \fBupdwtmp\fP()  と同じ作業を行うが、最後の引き数として \fIutmpx\fP 構造体を取るところが異なる。
77 .SH 関連項目
78 \fBgetutxent\fP(3), \fBwtmp\fP(5)
79 .SH この文書について
80 この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.79 の一部
81 である。プロジェクトの説明とバグ報告に関する情報は
82 http://www.kernel.org/doc/man\-pages/ に書かれている。