growfs.c (6149ed01a126d468431ecc4d20d0c00cb0040554) | growfs.c (fb14e73cb4062d7272ce6183d748adedd868906b) |
---|---|
1/*- 2 * SPDX-License-Identifier: BSD-4-Clause 3 * 4 * Copyright (c) 1980, 1989, 1993 The Regents of the University of California. 5 * Copyright (c) 2000 Christoph Herrmann, Thomas-Henning von Kamptz 6 * Copyright (c) 2012 The FreeBSD Foundation 7 * All rights reserved. 8 * --- 1435 unchanged lines hidden (view full) --- 1444 * Check if that partition is suitable for growing a file system. 1445 */ 1446 if (mediasize < 1) 1447 errx(1, "partition is unavailable"); 1448 1449 /* 1450 * Read the current superblock, and take a backup. 1451 */ | 1/*- 2 * SPDX-License-Identifier: BSD-4-Clause 3 * 4 * Copyright (c) 1980, 1989, 1993 The Regents of the University of California. 5 * Copyright (c) 2000 Christoph Herrmann, Thomas-Henning von Kamptz 6 * Copyright (c) 2012 The FreeBSD Foundation 7 * All rights reserved. 8 * --- 1435 unchanged lines hidden (view full) --- 1444 * Check if that partition is suitable for growing a file system. 1445 */ 1446 if (mediasize < 1) 1447 errx(1, "partition is unavailable"); 1448 1449 /* 1450 * Read the current superblock, and take a backup. 1451 */ |
1452 if ((ret = sbget(fsi, &fs, -1)) != 0) { | 1452 if ((ret = sbget(fsi, &fs, STDSB)) != 0) { |
1453 switch (ret) { 1454 case ENOENT: 1455 errx(1, "superblock not recognized"); 1456 default: 1457 errc(1, ret, "unable to read superblock"); 1458 } 1459 } 1460 memcpy(&osblock, fs, fs->fs_sbsize); --- 295 unchanged lines hidden --- | 1453 switch (ret) { 1454 case ENOENT: 1455 errx(1, "superblock not recognized"); 1456 default: 1457 errc(1, ret, "unable to read superblock"); 1458 } 1459 } 1460 memcpy(&osblock, fs, fs->fs_sbsize); --- 295 unchanged lines hidden --- |