diskfs / go-diskfs

MIT License
494 stars 112 forks source link

MBR: add partition table UUID and partition UUID #198

Closed thirdeyenick closed 8 months ago

thirdeyenick commented 8 months ago

This allows to retrieve the partition table UUID and partition UUID for MBR formatted disks. The partition table UUID (aka "disk identifier" or "disk signature") can be used to identify a disk when using the MBR format scheme. The partition UUID is then just the partition table UUID with the partitions index number appended.

deitch commented 8 months ago

I was surprised that mbr.initTable() was unused, but apparently it was.

The UUID is optional in MBR, but it cannot hurt, so might as well.

Thank you for this.

deitch commented 8 months ago

Some linting errors.

thirdeyenick commented 8 months ago

Some linting errors.

Should be fixed now.