patch-2.2.16 linux/arch/s390/kernel/sys_s390.c
Next file: linux/arch/s390/kernel/time.c
Previous file: linux/arch/s390/kernel/smp.c
Back to the patch index
Back to the overall index
- Lines: 28
- Date:
Wed Jun 7 14:26:42 2000
- Orig file:
v2.2.15/linux/arch/s390/kernel/sys_s390.c
- Orig date:
Tue Jan 4 10:12:12 2000
diff -urN v2.2.15/linux/arch/s390/kernel/sys_s390.c linux/arch/s390/kernel/sys_s390.c
@@ -115,8 +115,9 @@
* This is really horribly ugly.
*/
asmlinkage int sys_ipc (uint call, int first, int second,
- int third, void *ptr, long fifth)
+ int third, void *ptr)
{
+ struct ipc_kludge tmp;
int ret;
switch (call) {
@@ -137,9 +138,13 @@
second, third);
break;
case MSGRCV:
- return sys_msgrcv (first,
- (struct msgbuf *) ptr,
- second, fifth, third);
+ if (!ptr)
+ return -EINVAL;
+ if (copy_from_user (&tmp, (struct ipc_kludge *) ptr,
+ sizeof (struct ipc_kludge)))
+ return -EFAULT;
+ return sys_msgrcv (first, tmp.msgp,
+ second, tmp.msgtyp, third);
case MSGGET:
return sys_msgget ((key_t) first, second);
case MSGCTL:
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)