Source-Changes-HG archive

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

[src/trunk]: src/sys/kern Remove overzealous KASSERT: the refcount can be non...



details:   https://anonhg.NetBSD.org/src/rev/ca059b57a792
branches:  trunk
changeset: 756824:ca059b57a792
user:      pooka <pooka%NetBSD.org@localhost>
date:      Wed Aug 04 14:25:16 2010 +0000

description:
Remove overzealous KASSERT: the refcount can be non-zero if another
thread attempts to use a non-open file descriptor.  from ad

fixes PR kern/43694

diffstat:

 sys/kern/kern_descrip.c |  5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diffs (26 lines):

diff -r 960092cc8af4 -r ca059b57a792 sys/kern/kern_descrip.c
--- a/sys/kern/kern_descrip.c   Wed Aug 04 13:56:10 2010 +0000
+++ b/sys/kern/kern_descrip.c   Wed Aug 04 14:25:16 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_descrip.c,v 1.203 2010/07/01 02:38:30 rmind Exp $ */
+/*     $NetBSD: kern_descrip.c,v 1.204 2010/08/04 14:25:16 pooka Exp $ */
 
 /*-
  * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
@@ -70,7 +70,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_descrip.c,v 1.203 2010/07/01 02:38:30 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_descrip.c,v 1.204 2010/08/04 14:25:16 pooka Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -853,7 +853,6 @@
                        KASSERT(i >= NDFDFILE);
                        dt->dt_ff[i] = pool_cache_get(fdfile_cache, PR_WAITOK);
                }
-               KASSERT(dt->dt_ff[i]->ff_refcnt == 0);
                KASSERT(dt->dt_ff[i]->ff_file == NULL);
                fd_used(fdp, i);
                if (want <= fdp->fd_freefile) {



Home | Main Index | Thread Index | Old Index