| 162 | weak_alias(__pthread_key_create, pthread_key_create); |
| 163 | |
| 164 | void* pthread_getspecific(pthread_key_t key) { |
| 165 | if (key < 0 || key >= PTHREAD_KEYS_MAX) { |
| 166 | return NULL; |
| 167 | } |
| 168 | if (!tls_key_used[key]) { |
| 169 | return NULL; |
| 170 | } |
| 171 | return tls_entries[key]; |
| 172 | } |
| 173 | |
| 174 | int pthread_setspecific(pthread_key_t key, const void* value) { |
| 175 | if (key < 0 || key >= PTHREAD_KEYS_MAX) { |
no outgoing calls