Commit e2a18de5 authored by Mike Hibler's avatar Mike Hibler

Minor fixes for problems noticed on Moonshots.

parent fc3e39f3
......@@ -207,9 +207,9 @@ zappart(int fd, struct iz_disk *diskinfo, int pnum, int rpnum)
zapsize = SB_ZAPSIZE;
if (verbose && pinfo->type != IZTYPE_INVALID)
printf("%s: P%d: start=%lu, size=%lu\n",
printf("%s: P%d: start=%lu, size=%lu, type=0x%04x\n",
diskname, pnum, (unsigned long)pinfo->offset,
(unsigned long)pinfo->size);
(unsigned long)pinfo->size, pinfo->type);
/* Sanity checks */
switch (pinfo->type) {
......@@ -222,7 +222,7 @@ zappart(int fd, struct iz_disk *diskinfo, int pnum, int rpnum)
case IZTYPE_INVALID:
return 0;
}
if (pinfo->size < zapsize) {
if (pinfo->size*secsize < zapsize) {
if (pinfo->size > 0 && (verbose || !doit))
printf("%s: P%d: too small for superblock,"
" skipped\n", diskname, pnum);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment