summaryrefslogtreecommitdiff
path: root/sys/lib
diff options
context:
space:
mode:
authorMarc Aurele La France <tsi@cvs.openbsd.org>2007-03-16 21:49:00 +0000
committerMarc Aurele La France <tsi@cvs.openbsd.org>2007-03-16 21:49:00 +0000
commitc60aab5ca3f6ff1a5a7a6acc8647b408664c6ba7 (patch)
treefdfbe585edbad2b4cca0cf942c19d8088033eca2 /sys/lib
parentdddc112bc003394143b9807914c92cc0ba16d1e5 (diff)
Re-initialise f_seekp to 0 on a successful read_inode() return.
Fixes a problem that prevented the booting of a kernel that, to be found, needs more than one block per directory iin its path to be read. ok miod@, deraadt@
Diffstat (limited to 'sys/lib')
-rw-r--r--sys/lib/libsa/ufs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/lib/libsa/ufs.c b/sys/lib/libsa/ufs.c
index 863dcd1489e..afe58451c5c 100644
--- a/sys/lib/libsa/ufs.c
+++ b/sys/lib/libsa/ufs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ufs.c,v 1.17 2003/08/25 23:27:44 tedu Exp $ */
+/* $OpenBSD: ufs.c,v 1.18 2007/03/16 21:48:59 tsi Exp $ */
/* $NetBSD: ufs.c,v 1.16 1996/09/30 16:01:22 ws Exp $ */
/*-
@@ -145,6 +145,7 @@ read_inode(ino_t inumber, struct open_file *f)
for (level = 0; level < NIADDR; level++)
fp->f_blkno[level] = -1;
fp->f_buf_blkno = -1;
+ fp->f_seekp = 0;
}
out:
free(buf, fs->fs_bsize);