summaryrefslogtreecommitdiffstats
path: root/sys/gnu
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1998-10-29 09:44:12 +0000
committerpeter <peter@FreeBSD.org>1998-10-29 09:44:12 +0000
commit0c010ce2d17c43014f1f4879d166c8e0abdcb86e (patch)
treef71e6859785d1685983d6f7025ac1109799b74e3 /sys/gnu
parentd04d0ef759908218da7bff9ac600c58f5d64f20a (diff)
downloadFreeBSD-src-0c010ce2d17c43014f1f4879d166c8e0abdcb86e.zip
FreeBSD-src-0c010ce2d17c43014f1f4879d166c8e0abdcb86e.tar.gz
error return assignment was less than ideal. Fix the part that caused
warnings to be the same as the ffs code. Previously, any error from the UFS_UPDATE() call was lost (I think).
Diffstat (limited to 'sys/gnu')
-rw-r--r--sys/gnu/ext2fs/ext2_inode.c4
-rw-r--r--sys/gnu/fs/ext2fs/ext2_inode.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/sys/gnu/ext2fs/ext2_inode.c b/sys/gnu/ext2fs/ext2_inode.c
index b76410b..933d031 100644
--- a/sys/gnu/ext2fs/ext2_inode.c
+++ b/sys/gnu/ext2fs/ext2_inode.c
@@ -257,8 +257,8 @@ printf("ext2_truncate called %d to %d\n", VTOI(ovp)->i_number, length);
for (i = NDADDR - 1; i > lastblock; i--)
oip->i_db[i] = 0;
oip->i_flag |= IN_CHANGE | IN_UPDATE;
- if (error = UFS_UPDATE(ovp, &tv, &tv, MNT_WAIT))
- allerror = error;
+ allerror = UFS_UPDATE(ovp, &tv, &tv, MNT_WAIT);
+
/*
* Having written the new inode to disk, save its new configuration
* and put back the old block pointers long enough to process them.
diff --git a/sys/gnu/fs/ext2fs/ext2_inode.c b/sys/gnu/fs/ext2fs/ext2_inode.c
index b76410b..933d031 100644
--- a/sys/gnu/fs/ext2fs/ext2_inode.c
+++ b/sys/gnu/fs/ext2fs/ext2_inode.c
@@ -257,8 +257,8 @@ printf("ext2_truncate called %d to %d\n", VTOI(ovp)->i_number, length);
for (i = NDADDR - 1; i > lastblock; i--)
oip->i_db[i] = 0;
oip->i_flag |= IN_CHANGE | IN_UPDATE;
- if (error = UFS_UPDATE(ovp, &tv, &tv, MNT_WAIT))
- allerror = error;
+ allerror = UFS_UPDATE(ovp, &tv, &tv, MNT_WAIT);
+
/*
* Having written the new inode to disk, save its new configuration
* and put back the old block pointers long enough to process them.
OpenPOWER on IntegriCloud