svn commit: r194696 - in stable/7/sys: . contrib/pf gnu/fs/ext2fs
kern ufs/ufs
Konstantin Belousov
kib at FreeBSD.org
Tue Jun 23 11:00:00 UTC 2009
Author: kib
Date: Tue Jun 23 10:59:59 2009
New Revision: 194696
URL: http://svn.freebsd.org/changeset/base/194696
Log:
MFC r194296:
Do not use casts (int *)0 and (struct thread *)0 for the arguments of
vn_rdwr, use NULL.
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/gnu/fs/ext2fs/ext2_lookup.c
stable/7/sys/gnu/fs/ext2fs/ext2_vnops.c
stable/7/sys/kern/kern_acct.c
stable/7/sys/ufs/ufs/ufs_lookup.c
stable/7/sys/ufs/ufs/ufs_vnops.c
Modified: stable/7/sys/gnu/fs/ext2fs/ext2_lookup.c
==============================================================================
--- stable/7/sys/gnu/fs/ext2fs/ext2_lookup.c Tue Jun 23 10:55:21 2009 (r194695)
+++ stable/7/sys/gnu/fs/ext2fs/ext2_lookup.c Tue Jun 23 10:59:59 2009 (r194696)
@@ -1049,8 +1049,8 @@ ext2_checkpath(source, target, cred)
}
error = vn_rdwr(UIO_READ, vp, (caddr_t)&dirbuf,
sizeof (struct dirtemplate), (off_t)0, UIO_SYSSPACE,
- IO_NODELOCKED | IO_NOMACCHECK, cred, NOCRED, (int *)0,
- (struct thread *)0);
+ IO_NODELOCKED | IO_NOMACCHECK, cred, NOCRED, NULL,
+ NULL);
if (error != 0)
break;
namlen = dirbuf.dotdot_type; /* like ufs little-endian */
Modified: stable/7/sys/gnu/fs/ext2fs/ext2_vnops.c
==============================================================================
--- stable/7/sys/gnu/fs/ext2fs/ext2_vnops.c Tue Jun 23 10:55:21 2009 (r194695)
+++ stable/7/sys/gnu/fs/ext2fs/ext2_vnops.c Tue Jun 23 10:59:59 2009 (r194696)
@@ -1057,8 +1057,7 @@ abortit:
error = vn_rdwr(UIO_READ, fvp, (caddr_t)&dirbuf,
sizeof (struct dirtemplate), (off_t)0,
UIO_SYSSPACE, IO_NODELOCKED | IO_NOMACCHECK,
- tcnp->cn_cred, NOCRED, (int *)0,
- (struct thread *)0);
+ tcnp->cn_cred, NOCRED, NULL, NULL);
if (error == 0) {
/* Like ufs little-endian: */
namlen = dirbuf.dotdot_type;
@@ -1075,8 +1074,7 @@ abortit:
(off_t)0, UIO_SYSSPACE,
IO_NODELOCKED | IO_SYNC |
IO_NOMACCHECK, tcnp->cn_cred,
- NOCRED, (int *)0,
- (struct thread *)0);
+ NOCRED, NULL, NULL);
cache_purge(fdvp);
}
}
@@ -1212,7 +1210,7 @@ ext2_mkdir(ap)
error = vn_rdwr(UIO_WRITE, tvp, (caddr_t)&dirtemplate,
sizeof (dirtemplate), (off_t)0, UIO_SYSSPACE,
IO_NODELOCKED | IO_SYNC | IO_NOMACCHECK, cnp->cn_cred, NOCRED,
- (int *)0, (struct thread *)0);
+ NULL, NULL);
if (error) {
dp->i_nlink--;
dp->i_flag |= IN_CHANGE;
@@ -1349,7 +1347,7 @@ ext2_symlink(ap)
} else
error = vn_rdwr(UIO_WRITE, vp, ap->a_target, len, (off_t)0,
UIO_SYSSPACE, IO_NODELOCKED | IO_NOMACCHECK,
- ap->a_cnp->cn_cred, NOCRED, (int *)0, (struct thread *)0);
+ ap->a_cnp->cn_cred, NOCRED, NULL, NULL);
if (error)
vput(vp);
return (error);
Modified: stable/7/sys/kern/kern_acct.c
==============================================================================
--- stable/7/sys/kern/kern_acct.c Tue Jun 23 10:55:21 2009 (r194695)
+++ stable/7/sys/kern/kern_acct.c Tue Jun 23 10:59:59 2009 (r194696)
@@ -438,7 +438,7 @@ acct_process(struct thread *td)
VOP_LEASE(acct_vp, td, acct_cred, LEASE_WRITE);
ret = vn_rdwr(UIO_WRITE, acct_vp, (caddr_t)&acct, sizeof (acct),
(off_t)0, UIO_SYSSPACE, IO_APPEND|IO_UNIT, acct_cred, NOCRED,
- (int *)0, td);
+ NULL, td);
VFS_UNLOCK_GIANT(vfslocked);
sx_sunlock(&acct_sx);
return (ret);
Modified: stable/7/sys/ufs/ufs/ufs_lookup.c
==============================================================================
--- stable/7/sys/ufs/ufs/ufs_lookup.c Tue Jun 23 10:55:21 2009 (r194695)
+++ stable/7/sys/ufs/ufs/ufs_lookup.c Tue Jun 23 10:59:59 2009 (r194696)
@@ -1248,7 +1248,7 @@ ufs_dir_dd_ino(struct vnode *vp, struct
return (ENOTDIR);
error = vn_rdwr(UIO_READ, vp, (caddr_t)&dirbuf,
sizeof (struct dirtemplate), (off_t)0, UIO_SYSSPACE,
- IO_NODELOCKED | IO_NOMACCHECK, cred, NOCRED, (int *)0, NULL);
+ IO_NODELOCKED | IO_NOMACCHECK, cred, NOCRED, NULL, NULL);
if (error != 0)
return (error);
#if (BYTE_ORDER == LITTLE_ENDIAN)
Modified: stable/7/sys/ufs/ufs/ufs_vnops.c
==============================================================================
--- stable/7/sys/ufs/ufs/ufs_vnops.c Tue Jun 23 10:55:21 2009 (r194695)
+++ stable/7/sys/ufs/ufs/ufs_vnops.c Tue Jun 23 10:59:59 2009 (r194696)
@@ -1843,7 +1843,7 @@ ufs_symlink(ap)
} else
error = vn_rdwr(UIO_WRITE, vp, ap->a_target, len, (off_t)0,
UIO_SYSSPACE, IO_NODELOCKED | IO_NOMACCHECK,
- ap->a_cnp->cn_cred, NOCRED, (int *)0, (struct thread *)0);
+ ap->a_cnp->cn_cred, NOCRED, NULL, NULL);
if (error)
vput(vp);
return (error);
More information about the svn-src-stable-7
mailing list