CVSROOT:        /cvs
Module name:    src
Changes by:     k...@cvs.openbsd.org    2022/07/31 08:29:19

Modified files:
        sbin/disklabel : disklabel.8 disklabel.c editor.c 

Log message:
The geometry information in stuct disklabel is not used for
anything. Allowing modifications to it or displaying whatever
geometry was in use when the label was created leads to needless
inconsistency with the kernel and with the values displayed by,
e.g., fdisk(8).

Always set label fields d_secsize, d_nsectors, d_ntracks,
d_secpercyl, d_ncylinders to the current values used by the
kernel, obtained via DIOCGPDINFO. Ignore any values from the
on-disk label or the file -R uses.

Nuke editor command 'g' and restrict editor command 'e' to
changing d_type and d_packname.

Reply via email to