aboutsummaryrefslogtreecommitdiffstats
path: root/ipc/sem.c
diff options
context:
space:
mode:
Diffstat (limited to 'ipc/sem.c')
-rw-r--r--ipc/sem.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/ipc/sem.c b/ipc/sem.c
index 59696a840be1..18a78fe9c55b 100644
--- a/ipc/sem.c
+++ b/ipc/sem.c
@@ -227,8 +227,7 @@ asmlinkage long sys_semget (key_t key, int nsems, int semflg)
227 err = -EEXIST; 227 err = -EEXIST;
228 } else { 228 } else {
229 sma = sem_lock(id); 229 sma = sem_lock(id);
230 if(sma==NULL) 230 BUG_ON(sma==NULL);
231 BUG();
232 if (nsems > sma->sem_nsems) 231 if (nsems > sma->sem_nsems)
233 err = -EINVAL; 232 err = -EINVAL;
234 else if (ipcperms(&sma->sem_perm, semflg)) 233 else if (ipcperms(&sma->sem_perm, semflg))
@@ -1181,8 +1180,7 @@ retry_undos:
1181 1180
1182 sma = sem_lock(semid); 1181 sma = sem_lock(semid);
1183 if(sma==NULL) { 1182 if(sma==NULL) {
1184 if(queue.prev != NULL) 1183 BUG_ON(queue.prev != NULL);
1185 BUG();
1186 error = -EIDRM; 1184 error = -EIDRM;
1187 goto out_free; 1185 goto out_free;
1188 } 1186 }