]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Copy the argument instead of using a pointer to it.
authorUlrich Drepper <drepper@redhat.com>
Fri, 17 Sep 1999 15:37:19 +0000 (15:37 +0000)
committerUlrich Drepper <drepper@redhat.com>
Fri, 17 Sep 1999 15:37:19 +0000 (15:37 +0000)
sysdeps/unix/sysv/linux/semctl.c

index 4bc63bd71c372314b0d8d9d8947cb5780d6d65fb..7a29d7c10987997e9e9caf0a08de5259a4d5973a 100644 (file)
@@ -40,15 +40,15 @@ union semun
 int
 semctl (int semid, int semnum, int cmd, ...)
 {
-  union semun *arg;
+  union semun arg;
   va_list ap;
 
   va_start (ap, cmd);
 
-  /* Get a pointer the argument.  */
-  arg = &va_arg (ap, union semun);
+  /* Get the argument.  */
+  arg = va_arg (ap, union semun);
 
   va_end (ap);
 
-  return INLINE_SYSCALL (ipc, 5, IPCOP_semctl, semid, semnum, cmd, arg);
+  return INLINE_SYSCALL (ipc, 5, IPCOP_semctl, semid, semnum, cmd, &arg);
 }