'\" t .\" Hey Emacs! This file is -*- nroff -*- source. .\" .\" Copyright (C) 2006 Michael Kerrisk .\" .\" 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. .\" .\" Japanese Version Copyright (c) 2006 Akihiro MOTOKI all rights reserved. .\" Translated 2006-04-23, Akihiro MOTOKI .\" .TH MQ_CLOSE 3 2010-08-29 "Linux" "Linux Programmer's Manual" .\"O .SH NAME .SH 名前 .\"O mq_close \- close a message queue descriptor mq_close \- メッセージキュー記述子をクローズする .\"O .SH SYNOPSIS .SH 書式 .nf .B #include .sp .BI "int mq_close(mqd_t " mqdes ); .fi .sp .\"O Link with \fI\-lrt\fP. \fI\-lrt\fP でリンクする。 .\"O .SH DESCRIPTION .SH 説明 .\"O .BR mq_close () .\"O closes the message queue descriptor .\"O .IR mqdes . .BR mq_close () はメッセージキュー記述子 (message queue descriptor) .I mqdes をクローズする。 .\"O If the calling process has attached a notification request .\"O to this message queue via .\"O .IR mqdes , .\"O then this request is removed, .\"O and another process can now attach a notification request. 呼び出し元のプロセスが .I mqdes 経由でこのメッセージキューに通知要求 (notification request) を設定している場合、通知要求は削除され、他のプロセスがそのキューに 対して通知要求を設定できるようになる。 .\"O .SH RETURN VALUE .SH 返り値 .\"O On success .\"O .BR mq_close () .\"O returns 0; on error, \-1 is returned, with .\"O .I errno .\"O set to indicate the error. 成功すると、 .BR mq_close () は 0 を返す。エラーの場合、\-1 を返し、 .I errno にエラーを示す値を設定する。 .\"O .SH ERRORS .SH エラー .TP .B EBADF .\"O The descriptor specified in .\"O .I mqdes .\"O is invalid. .I mqdes で指定された記述子が不正である。 .\"O .SH CONFORMING TO .SH 準拠 POSIX.1-2001. .\"O .SH NOTES .SH 注意 .\"O All open message queues are automatically closed on process termination, .\"O or upon .\"O .BR execve (2). .\"Omotoki: 自動的にクローズされるのは message queue ではなく .\"Omotoki: message queue descriptor ? (cf. mq_overview(7)) プロセス終了時、もしくは .BR execve (2) 実行時に、全てのオープンされたメッセージキューは自動的にクローズされる。 .\"O .SH "SEE ALSO" .SH 関連項目 .BR mq_getattr (3), .BR mq_notify (3), .BR mq_open (3), .BR mq_receive (3), .BR mq_send (3), .BR mq_unlink (3), .BR mq_overview (7)