Don't cast the null residual pointer passed to vn_rdwr().

This commit is contained in:
thorpej 1998-07-28 18:34:52 +00:00
parent e8063e5201
commit 3ff8e6493a
17 changed files with 51 additions and 51 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.35 1998/07/28 18:30:54 thorpej Exp $ */
/* $NetBSD: vm_machdep.c,v 1.36 1998/07/28 18:34:52 thorpej Exp $ */
/*
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@ -31,7 +31,7 @@
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.35 1998/07/28 18:30:54 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.36 1998/07/28 18:34:52 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -92,7 +92,7 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.36 1998/07/10 20:24:35 mhitch Exp $ */
/* $NetBSD: vm_machdep.c,v 1.37 1998/07/28 18:34:53 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -295,13 +295,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (!error)
chdr->c_nseg++;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.27 1998/07/08 00:12:33 mark Exp $ */
/* $NetBSD: vm_machdep.c,v 1.28 1998/07/28 18:34:53 thorpej Exp $ */
/*
* Copyright (c) 1994-1998 Mark Brinicombe.
@ -464,13 +464,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cpustate, sizeof(cpustate),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.16 1998/06/11 16:31:45 thomas Exp $ */
/* $NetBSD: vm_machdep.c,v 1.17 1998/07/28 18:34:54 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -288,13 +288,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (!error)
chdr->c_nseg++;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.40 1998/02/16 20:58:32 thorpej Exp $ */
/* $NetBSD: vm_machdep.c,v 1.41 1998/07/28 18:34:54 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -187,13 +187,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred,
(int *)0, p);
NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.68 1998/02/10 14:11:15 mrg Exp $ */
/* $NetBSD: vm_machdep.c,v 1.69 1998/07/28 18:34:54 thorpej Exp $ */
/*-
* Copyright (c) 1995 Charles M. Hannum. All rights reserved.
@ -266,13 +266,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred,
(int *)0, p);
NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.28 1998/04/24 05:27:26 scottr Exp $ */
/* $NetBSD: vm_machdep.c,v 1.29 1998/07/28 18:34:55 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -228,13 +228,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (!error)
chdr->c_nseg++;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.25 1998/03/12 05:45:07 thorpej Exp $ */
/* $NetBSD: vm_machdep.c,v 1.26 1998/07/28 18:34:55 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -43,7 +43,7 @@
*/
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.25 1998/03/12 05:45:07 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.26 1998/07/28 18:34:55 thorpej Exp $");
#include "opt_uvm.h"
@ -218,7 +218,7 @@ cpu_coredump(p, vp, cred, chdr)
cseg.c_size = chdr->c_cpusize;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
@ -227,7 +227,7 @@ cpu_coredump(p, vp, cred, chdr)
(off_t)chdr -> c_cpusize,
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize),
UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT,
cred, (int *)NULL, p);
cred, NULL, p);
if (!error)
chdr->c_nseg++;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.12 1998/06/25 23:58:07 thorpej Exp $ */
/* $NetBSD: vm_machdep.c,v 1.13 1998/07/28 18:34:55 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -194,13 +194,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred,
(int *)0, p);
NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.1.1.1 1998/06/09 07:53:06 dbj Exp $ */
/* $NetBSD: vm_machdep.c,v 1.2 1998/07/28 18:34:56 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -173,13 +173,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred,
(int *)0, p);
NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.25 1998/07/06 09:42:56 matthias Exp $ */
/* $NetBSD: vm_machdep.c,v 1.26 1998/07/28 18:34:56 thorpej Exp $ */
/*-
* Copyright (c) 1996 Matthias Pfaller.
@ -245,13 +245,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred,
(int *)0, p);
NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.2 1996/07/16 23:25:04 thorpej Exp $ */
/* $NetBSD: vm_machdep.c,v 1.3 1998/07/28 18:34:57 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -196,7 +196,7 @@ cpu_coredump(p, vp, cred)
MachSaveCurFPState(p);
return (vn_rdwr(UIO_WRITE, vp, (caddr_t)p->p_addr, ctob(UPAGES),
(off_t)0, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred, (int *)NULL,
(off_t)0, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred, NULL,
p));
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.35 1998/07/17 23:05:35 pk Exp $ */
/* $NetBSD: vm_machdep.c,v 1.36 1998/07/28 18:34:57 thorpej Exp $ */
/*
* Copyright (c) 1996
@ -571,13 +571,13 @@ cpu_coredump(p, vp, cred, chdr)
cseg.c_size = chdr->c_cpusize;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (!error)
chdr->c_nseg++;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.2 1998/07/07 03:05:05 eeh Exp $ */
/* $NetBSD: vm_machdep.c,v 1.3 1998/07/28 18:34:57 thorpej Exp $ */
/*
* Copyright (c) 1996
@ -637,13 +637,13 @@ cpu_coredump(p, vp, cred, chdr)
cseg.c_size = chdr->c_cpusize;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (!error)
chdr->c_nseg++;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.42 1998/06/08 20:47:47 gwr Exp $ */
/* $NetBSD: vm_machdep.c,v 1.43 1998/07/28 18:34:58 thorpej Exp $ */
/*
* Copyright (c) 1994, 1995 Gordon W. Ross
@ -286,13 +286,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.39 1998/06/25 23:28:56 thorpej Exp $ */
/* $NetBSD: vm_machdep.c,v 1.40 1998/07/28 18:34:58 thorpej Exp $ */
/*
* Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@ -297,13 +297,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&state, sizeof(state),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)NULL, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (!error)
chdr->c_nseg++;

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.10 1998/06/30 11:59:13 msaitoh Exp $ */
/* $NetBSD: vm_machdep.c,v 1.11 1998/07/28 18:34:58 thorpej Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -187,13 +187,13 @@ cpu_coredump(p, vp, cred, chdr)
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&cseg, chdr->c_seghdrsize,
(off_t)chdr->c_hdrsize, UIO_SYSSPACE, IO_NODELOCKED|IO_UNIT, cred,
(int *)0, p);
NULL, p);
if (error)
return error;
error = vn_rdwr(UIO_WRITE, vp, (caddr_t)&md_core, sizeof(md_core),
(off_t)(chdr->c_hdrsize + chdr->c_seghdrsize), UIO_SYSSPACE,
IO_NODELOCKED|IO_UNIT, cred, (int *)0, p);
IO_NODELOCKED|IO_UNIT, cred, NULL, p);
if (error)
return error;