From 5dc107c9938a36ea720fe815c81da168e892d4b0 Mon Sep 17 00:00:00 2001 From: alfred Date: Fri, 30 Nov 2001 05:59:47 +0000 Subject: Make the same fix for writes to RAW objects. --- lib/libstand/write.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/libstand/write.c') diff --git a/lib/libstand/write.c b/lib/libstand/write.c index ea9d491..861a96f 100644 --- a/lib/libstand/write.c +++ b/lib/libstand/write.c @@ -89,8 +89,8 @@ write(fd, dest, bcount) btodb(f->f_offset), bcount, dest, &resid); if (errno) return (-1); - f->f_offset += resid; - return (resid); + f->f_offset += (bcount - resid); + return (bcount - resid); } resid = bcount; if ((errno = (f->f_ops->fo_write)(f, dest, bcount, &resid))) -- cgit v1.1