aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/libufs/cgroup.c1
-rw-r--r--lib/libufs/libufs.h1
-rw-r--r--lib/libufs/type.c1
3 files changed, 3 insertions, 0 deletions
diff --git a/lib/libufs/cgroup.c b/lib/libufs/cgroup.c
index 2948e618aeb6..a1d624df0049 100644
--- a/lib/libufs/cgroup.c
+++ b/lib/libufs/cgroup.c
@@ -68,5 +68,6 @@ cgread1(struct uufsd *disk, int c)
ERROR(disk, "unable to read cylinder group");
return -1;
}
+ disk->d_lcg = c;
return 1;
}
diff --git a/lib/libufs/libufs.h b/lib/libufs/libufs.h
index 996a4426bafa..7f7f3361b233 100644
--- a/lib/libufs/libufs.h
+++ b/lib/libufs/libufs.h
@@ -85,6 +85,7 @@ struct uufsd {
/* cylinder group storage */
} d_cgunion;
int d_ccg; /* current cylinder group */
+ int d_lcg; /* last cylinder group (in d_cg) */
const char *d_error; /* human readable disk error */
int d_mine; /* internal flags */
#define d_fs d_sbunion.d_fs
diff --git a/lib/libufs/type.c b/lib/libufs/type.c
index ef07730f4fde..4b8066ce2e3a 100644
--- a/lib/libufs/type.c
+++ b/lib/libufs/type.c
@@ -146,6 +146,7 @@ again: if (stat(name, &st) < 0) {
disk->d_inoblock = NULL;
disk->d_inomin = 0;
disk->d_inomax = 0;
+ disk->d_lcg = 0;
disk->d_mine = 0;
disk->d_ufs = 0;
disk->d_error = NULL;