Source-Changes-HG archive

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

[src/trunk]: src/sys/rump/librump/rumpvfs simplify



details:   https://anonhg.NetBSD.org/src/rev/78daeeee5d08
branches:  trunk
changeset: 759163:78daeeee5d08
user:      pooka <pooka%NetBSD.org@localhost>
date:      Tue Nov 30 18:20:41 2010 +0000

description:
simplify

diffstat:

 sys/rump/librump/rumpvfs/rumpfs.c |  14 +++-----------
 1 files changed, 3 insertions(+), 11 deletions(-)

diffs (36 lines):

diff -r 7a6fe81ea2ec -r 78daeeee5d08 sys/rump/librump/rumpvfs/rumpfs.c
--- a/sys/rump/librump/rumpvfs/rumpfs.c Tue Nov 30 18:19:47 2010 +0000
+++ b/sys/rump/librump/rumpvfs/rumpfs.c Tue Nov 30 18:20:41 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rumpfs.c,v 1.76 2010/11/30 10:48:27 dholland Exp $     */
+/*     $NetBSD: rumpfs.c,v 1.77 2010/11/30 18:20:41 pooka Exp $        */
 
 /*
  * Copyright (c) 2009, 2010 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rumpfs.c,v 1.76 2010/11/30 10:48:27 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rumpfs.c,v 1.77 2010/11/30 18:20:41 pooka Exp $");
 
 #include <sys/param.h>
 #include <sys/atomic.h>
@@ -661,16 +661,8 @@
                mutex_exit(&etfs_lock);
 
                if (found) {
-                       const char *offset;
-
-                       /* pointless as et_key is always the whole string */
-                       /*offset = strstr(cnp->cn_nameptr, et->et_key);*/
-                       offset = cnp->cn_nameptr;
-                       KASSERT(offset);
-
                        rn = et->et_rn;
-                       cnp->cn_consume += et->et_keylen
-                           - (cnp->cn_nameptr - offset) - cnp->cn_namelen;
+                       cnp->cn_consume += et->et_keylen - cnp->cn_namelen;
                        if (rn->rn_va.va_type != VDIR)
                                cnp->cn_flags &= ~REQUIREDIR;
                        goto getvnode;



Home | Main Index | Thread Index | Old Index