| 610 | } |
| 611 | |
| 612 | static int |
| 613 | sem_prison_cansee(struct prison *rpr, struct semid_kernel *semakptr) |
| 614 | { |
| 615 | |
| 616 | if (semakptr->cred == NULL || |
| 617 | !(rpr == semakptr->cred->cr_prison || |
| 618 | prison_ischild(rpr, semakptr->cred->cr_prison))) |
| 619 | return (EINVAL); |
| 620 | return (0); |
| 621 | } |
| 622 | |
| 623 | /* |
| 624 | * Note that the user-mode half of this passes a union, not a pointer. |
no test coverage detected