summaryrefslogtreecommitdiff
path: root/usr.bin/cvs/util.c
diff options
context:
space:
mode:
authorTodd T. Fries <todd@cvs.openbsd.org>2007-02-07 23:47:57 +0000
committerTodd T. Fries <todd@cvs.openbsd.org>2007-02-07 23:47:57 +0000
commitb98d700131c88a765e2fe7d375f64fbd38a3c4e9 (patch)
tree019bc15bddabd70e8296fe1faa163b988d82b9dd /usr.bin/cvs/util.c
parentf938fa13a69e9c1ac522703ef176f590d16bc0ef (diff)
fstat() -> lstat() in a few select cases,
this fixes a bug where opencvs update would abort if a link existed that pointed to a non-existent file/dir ok joris@
Diffstat (limited to 'usr.bin/cvs/util.c')
-rw-r--r--usr.bin/cvs/util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/cvs/util.c b/usr.bin/cvs/util.c
index 9896d6ff955..d6964bade62 100644
--- a/usr.bin/cvs/util.c
+++ b/usr.bin/cvs/util.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: util.c,v 1.103 2007/01/26 11:19:44 joris Exp $ */
+/* $OpenBSD: util.c,v 1.104 2007/02/07 23:47:56 todd Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* Copyright (c) 2005, 2006 Joris Vink <joris@openbsd.org>
@@ -490,7 +490,7 @@ cvs_rmdir(const char *path)
fatal("cvs_rmdir: path truncation");
if (ent->d_type == DT_UNKNOWN) {
- if (stat(fpath, &st) == -1)
+ if (lstat(fpath, &st) == -1)
fatal("'%s': %s", fpath, strerror(errno));
switch (st.st_mode & S_IFMT) {