Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src Drop an explicit sign-extension in fsck that shouldn't be ne...
details: https://anonhg.NetBSD.org/src/rev/437ac87f17d0
branches: trunk
changeset: 340819:437ac87f17d0
user: dholland <dholland%NetBSD.org@localhost>
date: Sat Oct 03 08:29:48 2015 +0000
description:
Drop an explicit sign-extension in fsck that shouldn't be needed any
more.
diffstat:
sbin/fsck_lfs/lfs.c | 4 +---
sys/ufs/lfs/lfs_accessors.h | 4 +++-
2 files changed, 4 insertions(+), 4 deletions(-)
diffs (43 lines):
diff -r fb46c43e1c40 -r 437ac87f17d0 sbin/fsck_lfs/lfs.c
--- a/sbin/fsck_lfs/lfs.c Sat Oct 03 08:29:34 2015 +0000
+++ b/sbin/fsck_lfs/lfs.c Sat Oct 03 08:29:48 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lfs.c,v 1.66 2015/10/03 08:29:34 dholland Exp $ */
+/* $NetBSD: lfs.c,v 1.67 2015/10/03 08:29:48 dholland Exp $ */
/*-
* Copyright (c) 2003 The NetBSD Foundation, Inc.
* All rights reserved.
@@ -1090,8 +1090,6 @@
if (error)
return (error);
- daddr = (daddr_t)((int32_t)daddr); /* XXX ondisk32 */
-
/*
* Do byte accounting all at once, so we can gracefully fail *before*
* we start assigning blocks.
diff -r fb46c43e1c40 -r 437ac87f17d0 sys/ufs/lfs/lfs_accessors.h
--- a/sys/ufs/lfs/lfs_accessors.h Sat Oct 03 08:29:34 2015 +0000
+++ b/sys/ufs/lfs/lfs_accessors.h Sat Oct 03 08:29:48 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lfs_accessors.h,v 1.35 2015/10/03 08:28:16 dholland Exp $ */
+/* $NetBSD: lfs_accessors.h,v 1.36 2015/10/03 08:29:48 dholland Exp $ */
/* from NetBSD: lfs.h,v 1.165 2015/07/24 06:59:32 dholland Exp */
/* from NetBSD: dinode.h,v 1.22 2013/01/22 09:39:18 dholland Exp */
@@ -501,6 +501,7 @@
if (fs->lfs_is64) {
return dip->u_64.di_db[ix];
} else {
+ /* note: this must sign-extend or UNWRITTEN gets trashed */
return dip->u_32.di_db[ix];
}
}
@@ -512,6 +513,7 @@
if (fs->lfs_is64) {
return dip->u_64.di_ib[ix];
} else {
+ /* note: this must sign-extend or UNWRITTEN gets trashed */
return dip->u_32.di_ib[ix];
}
}
Home |
Main Index |
Thread Index |
Old Index