OSDN Git Service

Retire LDP man-pages repository
[linuxjm/LDP_man-pages.git] / draft / man3 / mq_open.3
diff --git a/draft/man3/mq_open.3 b/draft/man3/mq_open.3
deleted file mode 100644 (file)
index 8ea2339..0000000
+++ /dev/null
@@ -1,151 +0,0 @@
-.\" t
-.\" Copyright (C) 2006 Michael Kerrisk <mtk.manpages@gmail.com>
-.\"
-.\" %%%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.
-.\"
-.\" Permission is granted to copy and distribute modified versions of this
-.\" manual under the conditions for verbatim copying, provided that the
-.\" entire resulting derived work is distributed under the terms of a
-.\" permission notice identical to this one.
-.\"
-.\" Since the Linux kernel and libraries are constantly changing, this
-.\" manual page may be incorrect or out-of-date.  The author(s) assume no
-.\" responsibility for errors or omissions, or for damages resulting from
-.\" the use of the information contained herein.  The author(s) may not
-.\" have taken the same level of care in the production of this manual,
-.\" which is licensed free of charge, as they might when working
-.\" professionally.
-.\"
-.\" Formatted or processed versions of this manual, if unaccompanied by
-.\" the source, must acknowledge the copyright and authors of this work.
-.\" %%%LICENSE_END
-.\"
-.\"*******************************************************************
-.\"
-.\" This file was generated with po4a. Translate the source file.
-.\"
-.\"*******************************************************************
-.\"
-.\" Japanese Version Copyright (c) 2006 Akihiro MOTOKI all rights reserved.
-.\" Translated 2006-04-23, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
-.\"
-.TH MQ_OPEN 3 2014\-12\-31 Linux "Linux Programmer's Manual"
-.SH 名前
-mq_open \- メッセージキューをオープンする
-.SH 書式
-.nf
-\fB#include <fcntl.h>\fP           /* For O_* constants */
-\fB#include <sys/stat.h>\fP        /* For mode constants */
-\fB#include <mqueue.h>\fP
-.sp
-\fBmqd_t mq_open(const char *\fP\fIname\fP\fB, int \fP\fIoflag\fP\fB);\fP
-\fBmqd_t mq_open(const char *\fP\fIname\fP\fB, int \fP\fIoflag\fP\fB, mode_t \fP\fImode\fP\fB,\fP
-\fB              struct mq_attr *\fP\fIattr\fP\fB);\fP
-.fi
-.sp
-\fI\-lrt\fP でリンクする。
-.SH 説明
-\fBmq_open\fP()  は、新しい POSIX メッセージキューを作成するか、既存のキューを オープンする。キューは \fIname\fP で識別される。
-\fIname\fP の構成の詳細については \fBmq_overview (7)\fP を参照。
-
-\fIoflag\fP 引き数には、関数呼び出しの操作を制御するフラグを指定する (oflag の値の定義は \fI<fcntl.h>\fP
-のインクルードにより得られる)。 \fIoflag\fP には、以下のうちいずれか一つを必ず指定しなければならない。
-.TP 
-\fBO_RDONLY\fP
-メッセージの受信専用としてキューをオープンする。
-.TP 
-\fBO_WRONLY\fP
-メッセージの送信専用としてキューをオープンする。
-.TP 
-\fBO_RDWR\fP
-メッセージの送受信両用としてキューをオープンする。
-.PP
-0 個以上の下記のフラグを、ビット単位の OR (論理和) で \fIoflag\fP に追加で指定できる。
-.TP 
-\fBO_CLOEXEC\fP (Linux 2.6.26 以降)
-.\" commit 269f21344b23e552c21c9e2d7ca258479dcd7a0a
-メッセージキュー記述子に close\-on\-exec フラグをセットする。 なぜこのフラグが有用かについての議論は \fBopen\fP(2) を参照。
-.TP 
-\fBO_CREAT\fP
-.\" In reality the filesystem IDs are used on Linux.
-存在しない場合、メッセージキューを作成する。 メッセージキューの所有者 (ユーザー ID) とグループ所有権 (グループ ID) は、
-それぞれ呼び出し元プロセスの実効ユーザー ID と実効グループ ID に設定される。
-.TP 
-\fBO_EXCL\fP
-\fBO_CREAT\fP が \fIoflag\fP に指定され、かつ指定された名前 \fIname\fP を持つキューがすでに存在する場合、エラー \fBEEXIST\fP
-で失敗する。
-.TP 
-\fBO_NONBLOCK\fP
-非停止 (nonblocking) モードでキューをオープンする。 \fBmq_receive\fP(3)  と \fBmq_send\fP(3)  は、通常は停止
-(block) する状況において、エラー \fBEAGAIN\fP で失敗するようになる。
-.PP
-\fIoflag\fP に \fBO_CREAT\fP を指定する場合、追加で 2つの引き数を与える必要がある。 \fImode\fP
-引き数は、新しいキューに適用される許可設定 (permission) を、 \fBopen\fP(2)  と同じように指定する (許可ビットのシンボル定義は
-\fI<sys/stat.h>\fP のインクルードにより得られる)。 許可設定はプロセスの umask でマスクされる。
-
-\fIattr\fP 引き数は、キューの属性を指定する。詳細は、 \fBmq_getattr\fP(3)  を参照。 \fIattr\fP が NULL
-の場合、キューは実装で定義されたデフォルト属性で作成される。 Linux 3.5 以降では、2 つの \fI/proc\fP
-ファイルがあり、これらのデフォルト値を制御できる。 詳細は \fBmq_overview\fP(7) を参照。
-.SH 返り値
-成功すると、 \fBmq_open\fP()  はメッセージキュー記述子 (message queue descriptor) を返す。
-メッセージキュー記述子は他のメッセージキュー関連の関数で使用される。 エラーの場合、 \fBmq_open\fP()  は \fI(mqd_t)\ \-1\fP
-を返し、 \fIerrno\fP にエラーを示す値を設定する。
-.SH エラー
-.TP 
-\fBEACCES\fP
-キューは存在するが、呼び出し元が指定されたモードでそのキュー をオープンする許可を持たない。
-.TP 
-\fBEACCES\fP
-.\" Note that this isn't consistent with the same case for sem_open()
-\fIname\fP にスラッシュが 2 個以上含まれていた。
-.TP 
-\fBEEXIST\fP
-\fIoflag\fP に \fBO_CREAT\fP と \fBO_EXCL\fP の両方が指定されたが、指定された名前 \fIname\fP を持つキューがすでに存在する。
-.TP 
-\fBEINVAL\fP
-\fIoflag\fP に \fBO_CREAT\fP が指定され、かつ \fIattr\fP が NULL 以外だが、 \fIattr\->mq_maxmsg\fP か
-\fIattr\->mq_msqsize\fP が不正であった。 これらのフィールドは両方とも 0 より大きくなければならない。
-プロセスが特権を持たない (\fBCAP_SYS_RESOURCE\fP ケーパビリティを持たない) 場合、 \fIattr\->mq_maxmsg\fP と
-\fIattr\->mq_msgsize\fP は、それぞれ上限 \fImsg_max\fP、 \fImsgsize_max\fP 以下でなければならない。
-また、特権プロセスの場合でも、 \fIattr\->mq_maxmsg\fP は \fBHARD_MAX\fP 上限を超えることはできない。
-(これらの上限に関する詳細は \fBmq_overview\fP(7)  を参照。)
-.TP 
-\fBEMFILE\fP
-そのプロセスがオープンしているファイルとメッセージキューの数が プロセス毎の上限に達している。
-.TP 
-\fBENAMETOOLONG\fP
-\fIname\fP が長過ぎる。
-.TP 
-\fBENFILE\fP
-システム全体でオープンしているファイルとメッセージキューの合計数が システム上限に達している。
-.TP 
-\fBENOENT\fP
-\fBO_CREAT\fP フラグが \fIoflag\fP に指定されなかったが、指定された名前 \fIname\fP を持つキューが存在しない。
-.TP 
-\fBENOENT\fP
-.\" Note that this isn't consistent with the same case for sem_open()
-\fIname\fP が "/" だけで、その後ろに他の文字が続いていなかった。
-.TP 
-\fBENOMEM\fP
-十分なメモリーがない。
-.TP 
-\fBENOSPC\fP
-新しいメッセージキューを作成するのに十分な空間がない。 このエラーはおそらく \fIqueues_max\fP 上限に抵触したため起こったのだろう。
-\fBmq_overview\fP(7)  を参照。
-.SH 属性
-.SS "マルチスレッディング (pthreads(7) 参照)"
-関数 \fBmq_open\fP() はスレッドセーフである。
-.SH 準拠
-POSIX.1\-2001.
-.SH バグ
-2.6.14 より前のカーネルには、 プロセスの umask が \fImode\fP で指定された許可設定に適用されなかった。
-.SH 関連項目
-\fBmq_close\fP(3), \fBmq_getattr\fP(3), \fBmq_notify\fP(3), \fBmq_receive\fP(3),
-\fBmq_send\fP(3), \fBmq_unlink\fP(3), \fBmq_overview\fP(7)
-.SH この文書について
-この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.79 の一部
-である。プロジェクトの説明とバグ報告に関する情報は
-http://www.kernel.org/doc/man\-pages/ に書かれている。