summaryrefslogtreecommitdiff
path: root/libnetfs/dir-lookup.c
diff options
context:
space:
mode:
authorThomas Bushnell <thomas@gnu.org>1999-03-05 22:22:23 +0000
committerThomas Bushnell <thomas@gnu.org>1999-03-05 22:22:23 +0000
commitbd9759ba8925b907fba8e3fb0a63a5ff3050a14f (patch)
tree77027663b1e24425dffe0c51535a53bca164d9a3 /libnetfs/dir-lookup.c
parent77b6f43a9626ed1939a626ec91936ac78d1415cb (diff)
Thu Mar 4 07:18:21 1999 Joel N. Weber II <devnull@theobromine.ai.mit.edu>
* dir-lookup.c (netfs_S_dir_lookup): Only set newnode to 1 if the lookup does not need to be retried as a result of getting EEXIST.
Diffstat (limited to 'libnetfs/dir-lookup.c')
-rw-r--r--libnetfs/dir-lookup.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libnetfs/dir-lookup.c b/libnetfs/dir-lookup.c
index b9baeb06..29037542 100644
--- a/libnetfs/dir-lookup.c
+++ b/libnetfs/dir-lookup.c
@@ -1,5 +1,5 @@
/*
- Copyright (C) 1995, 96, 97, 98, 99 Free Software Foundation, Inc.
+ Copyright (C) 1995, 96, 97, 98, 1999 Free Software Foundation, Inc.
Written by Michael I. Bushnell, p/BSG.
This file is part of the GNU Hurd.
@@ -162,7 +162,6 @@ netfs_S_dir_lookup (struct protid *diruser,
mutex_lock (&dnp->lock);
error = netfs_attempt_create_file (diruser->user, dnp,
filename, mode, &np);
- newnode = 1;
/* If someone has already created the file (between our lookup
and this create) then we just got EEXIST. If we are
@@ -172,6 +171,8 @@ netfs_S_dir_lookup (struct protid *diruser,
mutex_lock (&dnp->lock);
goto retry_lookup;
}
+
+ newnode = 1;
}
/* All remaining errors get returned to the user */