| <assertions> |
| <assertion id="1" tag="ref:XSH6:35397:35399 pt:CX pt:THR"> |
| pthread_sigmask( ) function is used to examine or change (or both) the calling thread's signal |
| mask, independent of the number of threads the process contains. The function shall be |
| equivalent to sigprocmask( ), but with the ability to be used in a thread of a multi-threaded |
| process. |
| </assertion> |
| <assertion id="2" tag="ref:XSH6:35400:35401 pt:CX"> |
| The sigprocmask( ) function is used to examine or change (or both) the signal mask of the calling |
| thread of a single-threaded process. |
| </assertion> |
| <assertion id="3" tag="ref:XSH6:35402:35403 pt:CX pt:THR"> |
| The argument set points to a set of signals to be used to change the currently blocked set, unless the |
| argument is a null pointer. |
| </assertion> |
| <assertion id="4" tag="ref:XSH6:35406:35407 pt:CX pt:THR"> |
| The resulting set shall be the union of the current set and the signal set pointed to by set, if the value |
| of the argument how is SIG_BLOCK. |
| </assertion> |
| <assertion id="5" tag="ref:XSH6:35408:35408 pt:CX pt:THR"> |
| The resulting set shall be the signal set pointed to by set, if the value of the argument how is SIG_SETMASK |
| </assertion> |
| <assertion id="6" tag="ref:XSH6:35409:35410 pt:CX pt:THR"> |
| The resulting set shall be the intersection of the current set and the complement of the signal set |
| pointed to by set, if the value of the argument how is SIG_UNBLOCK |
| </assertion> |
| <assertion id="7" tag="ref:XSH6:35411:35412 pt:CX pt:THR"> |
| The previous mask shall be stored in the location pointed to by oset, if the argument oset is not a null |
| pointer. |
| </assertion> |
| <assertion id="8" tag="ref:XSH6:35412:35414 pt:CX pt:THR"> |
| The value of the argument how is not significant and the process's signal mask shall be unchanged, and |
| thus the call can be used to enquire about currently blocked signals, if the argument set is a null |
| pointer. |
| </assertion> |
| <assertion id="9" tag="ref:XSH6:35415:35416 pt:CX pt:THR"> |
| After the call to sigprocmask(), if there are any pending unblocked signals, at least one of those |
| signals shall be delivered before the call to sigprocmask() returns. |
| </assertion> |
| <assertion id="10" tag="ref:XSH6:35417:35418 pt:CX pt:THR"> |
| The system shall not allow the blocking of signals which cannot be ignored, and shall not cause an error |
| to be indicated. |
| </assertion> |
| <assertion id="11" tag="ref:XSH6:35419:35421 pt:CX pt:THR"> |
| If any of the SIGFPE, SIGILL, SIGSEGV, or SIGBUS signals are generated while they are blocked, and the |
| signal was not generated by the kill(), sigqueue() or raise()functions, the result is undefined. |
| </assertion> |
| <assertion id="12" tag="ref:XSH6:35422:35422 pt:CX pt:THR"> |
| The thread's signal mask shall not be changed, if sigprocmask( ) fails. |
| </assertion> |
| <assertion id="13" tag="ref:XSH6:35423:35423 pt:CX"> |
| In a multi-threaded process, the use of the sigprocmask( ) function is unspecified. |
| </assertion> |
| <assertion id="14" tag="ref:XSH6:35425:35426 pt:THR"> |
| pthread_sigmask( ) shall return 0, Upon successful completion; otherwise, it shall return the corresponding |
| error number. |
| </assertion> |
| <assertion id="15" tag="ref:XSH6:35427:35428 pt:CX pt:THR"> |
| sigprocmask( ) shall return 0, Upon successful completion; otherwise, it shall return -1 |
| and errno shall be set to indicate the error, and the process' signal mask shall be unchanged. |
| </assertion> |
| <assertion id="16" tag="ref:XSH6:35430:35431 pt:THR"> |
| An errno value of [EINVAL] shall be returned and the pthreadsigmask() function shall fail, if the |
| value of |
| the how argument is not equal to one of the defined values. |
| </assertion> |
| <assertion id="17" tag="ref:XSH6:35430:35431 pt:CX pt:THR"> |
| An errno value of [EINVAL] shall be returned and the sigprocmask() function shall fail, if the value of |
| the how argument is not equal to one of the defined values. |
| </assertion> |
| <assertion id="18" tag="ref:XSH6:35432:35432 pt:THR"> |
| An error code of [EINTR] shall not be returned by the pthread_sigmask( ) function. |
| </assertion> |
| </assertions> |