diff options
author | Todd T. Fries <todd@cvs.openbsd.org> | 2007-02-07 23:47:57 +0000 |
---|---|---|
committer | Todd T. Fries <todd@cvs.openbsd.org> | 2007-02-07 23:47:57 +0000 |
commit | b98d700131c88a765e2fe7d375f64fbd38a3c4e9 (patch) | |
tree | 019bc15bddabd70e8296fe1faa163b988d82b9dd /usr.bin/cvs/file.c | |
parent | f938fa13a69e9c1ac522703ef176f590d16bc0ef (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/file.c')
-rw-r--r-- | usr.bin/cvs/file.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/cvs/file.c b/usr.bin/cvs/file.c index 3868efb286d..130e28ff4c6 100644 --- a/usr.bin/cvs/file.c +++ b/usr.bin/cvs/file.c @@ -1,4 +1,4 @@ -/* $OpenBSD: file.c,v 1.183 2007/01/31 21:07:35 xsa Exp $ */ +/* $OpenBSD: file.c,v 1.184 2007/02/07 23:47:56 todd Exp $ */ /* * Copyright (c) 2006 Joris Vink <joris@openbsd.org> * Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org> @@ -415,10 +415,10 @@ cvs_file_walkdir(struct cvs_file *cf, struct cvs_recursion *cr) /* * nfs and afs will show d_type as DT_UNKNOWN * for files and/or directories so when we encounter - * this we call stat() on the path to be sure. + * this we call lstat() on the path to be sure. */ if (dp->d_type == DT_UNKNOWN) { - if (stat(fpath, &st) == -1) + if (lstat(fpath, &st) == -1) fatal("'%s': %s", fpath, strerror(errno)); |