aboutsummaryrefslogtreecommitdiff
path: root/sbin/fsdb
diff options
context:
space:
mode:
authorGlen Barber <gjb@FreeBSD.org>2013-03-23 08:57:14 +0000
committerGlen Barber <gjb@FreeBSD.org>2013-03-23 08:57:14 +0000
commite1c7cfb20052715b26698bc369cfdc2ae22dd0bc (patch)
treed879c15a99b5699c9d09bd9acb2d1976c05ea862 /sbin/fsdb
parentaaf2546b672b666a0e8765985ba034d6dbb6f036 (diff)
downloadsrc-e1c7cfb20052715b26698bc369cfdc2ae22dd0bc.tar.gz
src-e1c7cfb20052715b26698bc369cfdc2ae22dd0bc.zip
Revert r248639 to fix build failure on head/
Notes
Notes: svn path=/head/; revision=248643
Diffstat (limited to 'sbin/fsdb')
-rw-r--r--sbin/fsdb/fsdb.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sbin/fsdb/fsdb.c b/sbin/fsdb/fsdb.c
index 1315aeca0acb..e169061e9f65 100644
--- a/sbin/fsdb/fsdb.c
+++ b/sbin/fsdb/fsdb.c
@@ -441,8 +441,7 @@ CMDFUNCSTART(findblk)
ino_t inum, inosused;
uint32_t *wantedblk32;
uint64_t *wantedblk64;
- struct bufarea *cgbp;
- struct cg *cgp;
+ struct cg *cgp = &cgrp;
int c, i, is_ufs2;
wantedblksize = (argc - 1);
@@ -474,8 +473,8 @@ CMDFUNCSTART(findblk)
*/
inum = c * sblock.fs_ipg;
/* Read cylinder group. */
- cgbp = cgget(c);
- cgp = cgbp->b_un.b_cg;
+ getblk(&cgblk, cgtod(&sblock, c), sblock.fs_cgsize);
+ memcpy(cgp, cgblk.b_un.b_cg, sblock.fs_cgsize);
/*
* Get a highest used inode number for a given cylinder group.
* For UFS1 all inodes initialized at the newfs stage.