Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sbin/newfs ufs2 disk addresses in dp2->di_db[] must be swapp...
details: https://anonhg.NetBSD.org/src/rev/2ede0a88a5a0
branches: trunk
changeset: 581592:2ede0a88a5a0
user: dbj <dbj%NetBSD.org@localhost>
date: Fri Jun 03 01:10:50 2005 +0000
description:
ufs2 disk addresses in dp2->di_db[] must be swapped with bswap64, not bswap32
diffstat:
sbin/newfs/mkfs.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r eade558704cb -r 2ede0a88a5a0 sbin/newfs/mkfs.c
--- a/sbin/newfs/mkfs.c Thu Jun 02 21:38:17 2005 +0000
+++ b/sbin/newfs/mkfs.c Fri Jun 03 01:10:50 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mkfs.c,v 1.88 2004/04/14 22:06:33 dbj Exp $ */
+/* $NetBSD: mkfs.c,v 1.89 2005/06/03 01:10:50 dbj Exp $ */
/*
* Copyright (c) 1980, 1989, 1993
@@ -73,7 +73,7 @@
#if 0
static char sccsid[] = "@(#)mkfs.c 8.11 (Berkeley) 5/3/95";
#else
-__RCSID("$NetBSD: mkfs.c,v 1.88 2004/04/14 22:06:33 dbj Exp $");
+__RCSID("$NetBSD: mkfs.c,v 1.89 2005/06/03 01:10:50 dbj Exp $");
#endif
#endif /* not lint */
@@ -1239,7 +1239,7 @@
if (needswap) {
ffs_dinode2_swap(&ip->dp2, dp2);
for (i=0; i<NDADDR + NIADDR; i++)
- dp2->di_db[i] = bswap32(ip->dp2.di_db[i]);
+ dp2->di_db[i] = bswap64(ip->dp2.di_db[i]);
} else
*dp2 = ip->dp2;
dp2->di_gen = arc4random() & INT32_MAX;
Home |
Main Index |
Thread Index |
Old Index