| Top |
| struct fdisk_labelitem * | fdisk_new_labelitem () |
| void | fdisk_ref_labelitem () |
| int | fdisk_reset_labelitem () |
| void | fdisk_unref_labelitem () |
| const char * | fdisk_labelitem_get_name () |
| int | fdisk_labelitem_get_id () |
| int | fdisk_labelitem_get_data_u64 () |
| int | fdisk_labelitem_get_data_string () |
| int | fdisk_labelitem_is_string () |
| int | fdisk_labelitem_is_number () |
| struct | fdisk_labelitem |
| enum | fdisk_labelitem_bsd |
| enum | fdisk_labelitem_gen |
| enum | fdisk_labelitem_gpt |
| enum | fdisk_labelitem_sgi |
| enum | fdisk_labelitem_sun |
The labelitem is label specific items stored in the partition table header. The information provided by labelitems are not specific to the partitions.
For example
1 2 3 4 5 6 |
struct fdisk_labelitem *item = fdisk_new_labelitem(); fdisk_get_disklabel_item(cxt, GPT_LABELITEM_ALTLBA, item); print("Backup header LBA: %ju\n", fdisk_labelitem_get_data_u64(item)); fdisk_unref_labelitem(item); |
returns LBA of the alternative GPT header.
See also fdisk_get_disklabel_item(). The IDs are generic (e.g.
FDISK_LABEL_ITEM_*) and label specific ((e.g. GPT_LABELITEM_*).
void
fdisk_ref_labelitem (struct fdisk_labelitem *li);
Increments reference counter.
Since: 2.29
int
fdisk_reset_labelitem (struct fdisk_labelitem *li);
Zeroize data stored in the li
(does not modify anything in disk label).
Since: 2.29
void
fdisk_unref_labelitem (struct fdisk_labelitem *li);
Decrements reference counter, on zero the li
is automatically
deallocated.
Since: 2.29
const char *
fdisk_labelitem_get_name (struct fdisk_labelitem *li);
Since: 2.29
int fdisk_labelitem_get_data_u64 (struct fdisk_labelitem *li,uint64_t *data);
Since: 2.29
int fdisk_labelitem_get_data_string (struct fdisk_labelitem *li,const char **data);
Since: 2.29
int
fdisk_labelitem_is_string (struct fdisk_labelitem *li);
Since: 2.29
int
fdisk_labelitem_is_number (struct fdisk_labelitem *li);
Since: 2.29
struct fdisk_labelitem;
library handler for label specific information. See generic FDISK_LABELITEM_* and label specific {GPT,MBR,..}_LABELITEM_*.