half-stubbed version as we don't really well support signals */
| 1298 | |
| 1299 | /* half-stubbed version as we don't really well support signals */ |
| 1300 | int |
| 1301 | pthread_kill (pthread_t t, int sig) |
| 1302 | { |
| 1303 | struct _pthread_v *tv; |
| 1304 | |
| 1305 | pthread_mutex_lock (&mtx_pthr_locked); |
| 1306 | tv = __pthread_get_pointer (t); |
| 1307 | if (!tv || t != tv->x || tv->in_cancel || tv->ended || tv->h == NULL |
| 1308 | || tv->h == INVALID_HANDLE_VALUE) |
| 1309 | { |
| 1310 | pthread_mutex_unlock (&mtx_pthr_locked); |
| 1311 | return ESRCH; |
| 1312 | } |
| 1313 | pthread_mutex_unlock (&mtx_pthr_locked); |
| 1314 | if (!sig) |
| 1315 | return 0; |
| 1316 | if (sig < SIGINT || sig > NSIG) |
| 1317 | return EINVAL; |
| 1318 | return pthread_cancel(t); |
| 1319 | } |
| 1320 | |
| 1321 | unsigned |
| 1322 | _pthread_get_state (const pthread_attr_t *attr, unsigned flag) |
nothing calls this directly
no test coverage detected