CEEOPSS
C library interface: pthread_setspecific()
CEEOPSS establishes a thread-specific value to a key obtained by a previous call to CEEOPKC. Different threads can bind different values to the same key.
When successful, CEEOPSS obtains the value from the location referred to by value and assigns it to a Language Environment-managed storage location associated with the key.
Syntax
void CEEOPSS (key, value,
[fc])
CEE_THDKEY *key;
CEE_TOKEN *value;
FEED_BACK *fc;
- CEEOPSS
- Call this CWI interface as follows:
L R15,CEECAALEOV-CEECAA(,R12) CAA address is in R12 L R15,0100(,R15) BALR R14,R15
- key (input)
- The identifier to associate with the value. The identifier is generated by a previous call to CEEOPKC.
- value (input)
- The value to be associated with the key identifier. The value binding for the key is specific to the thread. The value typically is the address of a storage area to be unallocated during thread termination by the destructor function.
- fc (output/optional)
- The feedback code returned by the service. It indicates the degree of success in creating the new key.
The following message identifiers and associated severities can be returned by the service in the feedback code fc.
Condition | Description category | Description value |
---|---|---|
CEE000 | Severity | 0 |
Msg_No | 0000 | |
Message | The service completed successfully. | |
CEE5CP | Severity | 3 |
Msg_No | 5529 | |
Message | There was not enough storage available to bind the value to the key. | |
CEE5CQ | Severity | 3 |
Msg_No | 5530 | |
Message | The key value is not valid. The key identifier is not one of the keys previously defined by CEEOPKC. | |
CEE5CR | Severity | 3 |
Msg_No | 5531 | |
Message | Thread termination is in progress. This operation is not allowed. A key set operation is not permitted during thread termination. | |
CEE5CT | Severity | 3 |
Msg_No | 5533 | |
Message | Incorrect user parameter caused a program exception. |
Usage Notes:
- Different threads can bind different values to the same key.
- Calling this function during thread termination can result in undefined behavior.