From b8351fcda2af435587af452d2cf8727e0715a0a4 Mon Sep 17 00:00:00 2001 From: kib Date: Tue, 16 Jun 2009 15:13:45 +0000 Subject: Do not use casts (int *)0 and (struct thread *)0 for the arguments of vn_rdwr, use NULL. Reviewed by: jhb MFC after: 1 week --- sys/gnu/fs/ext2fs/ext2_lookup.c | 4 ++-- sys/gnu/fs/ext2fs/ext2_vnops.c | 10 ++++------ 2 files changed, 6 insertions(+), 8 deletions(-) (limited to 'sys/gnu') diff --git a/sys/gnu/fs/ext2fs/ext2_lookup.c b/sys/gnu/fs/ext2fs/ext2_lookup.c index 261d85f..6ab41e5 100644 --- a/sys/gnu/fs/ext2fs/ext2_lookup.c +++ b/sys/gnu/fs/ext2fs/ext2_lookup.c @@ -1048,8 +1048,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 */ diff --git a/sys/gnu/fs/ext2fs/ext2_vnops.c b/sys/gnu/fs/ext2fs/ext2_vnops.c index 248c433..41643e3 100644 --- a/sys/gnu/fs/ext2fs/ext2_vnops.c +++ b/sys/gnu/fs/ext2fs/ext2_vnops.c @@ -1048,8 +1048,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; @@ -1066,8 +1065,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); } } @@ -1203,7 +1201,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; @@ -1340,7 +1338,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); -- cgit v1.1