| 840 | shmexit(struct vmspace *vm) |
| 841 | #else |
| 842 | static void |
| 843 | shmexit_myhook(struct vmspace *vm) |
| 844 | #endif |
| 845 | { |
| 846 | struct shmmap_state *base, *shm; |
| 847 | int i; |
| 848 | |
| 849 | base = vm->vm_shm; |
| 850 | if (base != NULL) { |
| 851 | vm->vm_shm = NULL; |
| 852 | SYSVSHM_LOCK(); |
| 853 | for (i = 0, shm = base; i < shminfo.shmseg; i++, shm++) { |
| 854 | if (shm->shmid != -1) |
| 855 | shm_delete_mapping(vm, shm); |
| 856 | } |
| 857 | SYSVSHM_UNLOCK(); |
| 858 | free(base, M_SHM); |
| 859 | } |
| 860 | } |
| 861 | |
| 862 | static void |
| 863 | shmrealloc(void) |
nothing calls this directly
no test coverage detected