Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/miscfs/specfs Revert previous, and explain why.



details:   https://anonhg.NetBSD.org/src/rev/239b07e0eb61
branches:  trunk
changeset: 339145:239b07e0eb61
user:      christos <christos%NetBSD.org@localhost>
date:      Mon Jun 29 16:25:49 2015 +0000

description:
Revert previous, and explain why.

diffstat:

 sys/miscfs/specfs/spec_vnops.c |  11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)

diffs (32 lines):

diff -r 34b6d17b30ae -r 239b07e0eb61 sys/miscfs/specfs/spec_vnops.c
--- a/sys/miscfs/specfs/spec_vnops.c    Mon Jun 29 16:20:14 2015 +0000
+++ b/sys/miscfs/specfs/spec_vnops.c    Mon Jun 29 16:25:49 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: spec_vnops.c,v 1.149 2015/06/29 15:39:40 christos Exp $        */
+/*     $NetBSD: spec_vnops.c,v 1.150 2015/06/29 16:25:49 christos Exp $        */
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -58,7 +58,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: spec_vnops.c,v 1.149 2015/06/29 15:39:40 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: spec_vnops.c,v 1.150 2015/06/29 16:25:49 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/proc.h>
@@ -1097,7 +1097,12 @@
        struct vnode *vp = ap->a_vp;
 
        KASSERT(vp->v_mount == dead_rootmount);
-       vcache_remove(vp->v_mount, vp, sizeof(*vp));
+       /*
+        * The key is the pointer itself, see:
+        * miscfs/deadfs/dead_vfsops::dead_newvnode()
+        * coverity[sizeof_mismatch]
+        */
+       vcache_remove(vp->v_mount, vp, sizeof(struct vnode *));
        return 0;
 }
 



Home | Main Index | Thread Index | Old Index