Lines Matching defs:shmid
62 int shmid;
96 if ((shmid = shmget(key, SIZE, IPC_CREAT | 0666)) < 0) {
98 tst_brkm(TFAIL, NULL, "Error: shmid = %d", shmid);
111 if ((c1 = shmat(shmid, NULL, 0)) == (char *)-1) {
113 "Error shmat: iter %d, shmid = %d", i,
114 shmid);
126 rm_shm(shmid);
130 static int rm_shm(int shmid)
132 if (shmctl(shmid, IPC_RMID, NULL) == -1) {
136 "shmctl Failed to remove: shmid = %d, errno = %d",
137 shmid, errno);
148 if ((c1 = shmat(shmid, NULL, 0)) == (char *)-1) {
151 "Error:child proc: shmat: iter %d, shmid = %d",
152 i, shmid);
165 rm_shm(shmid);