logo

oasis-root

Compiled tree of Oasis Linux based on own branch at <https://hacktivis.me/git/oasis/> git clone https://anongit.hacktivis.me/git/oasis-root.git

mq_setattr.3p (3275B)


  1. '\" et
  2. .TH MQ_SETATTR "3P" 2017 "IEEE/The Open Group" "POSIX Programmer's Manual"
  3. .\"
  4. .SH PROLOG
  5. This manual page is part of the POSIX Programmer's Manual.
  6. The Linux implementation of this interface may differ (consult
  7. the corresponding Linux manual page for details of Linux behavior),
  8. or the interface may not be implemented on Linux.
  9. .\"
  10. .SH NAME
  11. mq_setattr
  12. \(em set message queue attributes
  13. (\fBREALTIME\fP)
  14. .SH SYNOPSIS
  15. .LP
  16. .nf
  17. #include <mqueue.h>
  18. .P
  19. int mq_setattr(mqd_t \fImqdes\fP, const struct mq_attr *restrict \fImqstat\fP,
  20. struct mq_attr *restrict \fIomqstat\fP);
  21. .fi
  22. .SH DESCRIPTION
  23. The
  24. \fImq_setattr\fR()
  25. function shall set attributes associated with the open message queue
  26. description referenced by the message queue descriptor specified by
  27. .IR mqdes .
  28. .P
  29. The message queue attributes corresponding to the following members
  30. defined in the
  31. .BR mq_attr
  32. structure shall be set to the specified values upon successful
  33. completion of
  34. \fImq_setattr\fR():
  35. .IP "\fImq_flags\fP" 12
  36. The value of this member is the bitwise-logical OR of zero or more of
  37. O_NONBLOCK and any implementation-defined flags.
  38. .P
  39. The values of the
  40. .IR mq_maxmsg ,
  41. .IR mq_msgsize ,
  42. and
  43. .IR mq_curmsgs
  44. members of the
  45. .BR mq_attr
  46. structure shall be ignored by
  47. \fImq_setattr\fR().
  48. .P
  49. If
  50. .IR omqstat
  51. is non-NULL, the
  52. \fImq_setattr\fR()
  53. function shall store, in the location referenced by
  54. .IR omqstat ,
  55. the previous message queue attributes and the current queue status.
  56. These values shall be the same as would be returned by a call to
  57. \fImq_getattr\fR()
  58. at that point.
  59. .SH "RETURN VALUE"
  60. Upon successful completion, the function shall return a value of zero
  61. and the attributes of the message queue shall have been changed as
  62. specified.
  63. .P
  64. Otherwise, the message queue attributes shall be unchanged, and the
  65. function shall return a value of \-1 and set
  66. .IR errno
  67. to indicate the error.
  68. .SH ERRORS
  69. The
  70. \fImq_setattr\fR()
  71. function shall fail if:
  72. .TP
  73. .BR EBADF
  74. The
  75. .IR mqdes
  76. argument is not a valid message queue descriptor.
  77. .LP
  78. .IR "The following sections are informative."
  79. .SH EXAMPLES
  80. None.
  81. .SH "APPLICATION USAGE"
  82. None.
  83. .SH RATIONALE
  84. None.
  85. .SH "FUTURE DIRECTIONS"
  86. None.
  87. .SH "SEE ALSO"
  88. .IR "\fImq_open\fR\^(\|)",
  89. .IR "\fImq_send\fR\^(\|)",
  90. .IR "\fImsgctl\fR\^(\|)",
  91. .IR "\fImsgget\fR\^(\|)",
  92. .IR "\fImsgrcv\fR\^(\|)",
  93. .IR "\fImsgsnd\fR\^(\|)"
  94. .P
  95. The Base Definitions volume of POSIX.1\(hy2017,
  96. .IR "\fB<mqueue.h>\fP"
  97. .\"
  98. .SH COPYRIGHT
  99. Portions of this text are reprinted and reproduced in electronic form
  100. from IEEE Std 1003.1-2017, Standard for Information Technology
  101. -- Portable Operating System Interface (POSIX), The Open Group Base
  102. Specifications Issue 7, 2018 Edition,
  103. Copyright (C) 2018 by the Institute of
  104. Electrical and Electronics Engineers, Inc and The Open Group.
  105. In the event of any discrepancy between this version and the original IEEE and
  106. The Open Group Standard, the original IEEE and The Open Group Standard
  107. is the referee document. The original Standard can be obtained online at
  108. http://www.opengroup.org/unix/online.html .
  109. .PP
  110. Any typographical or formatting errors that appear
  111. in this page are most likely
  112. to have been introduced during the conversion of the source files to
  113. man page format. To report such errors, see
  114. https://www.kernel.org/doc/man-pages/reporting_bugs.html .