mirror of
https://git.proxmox.com/git/efi-boot-shim
synced 2025-08-17 10:50:16 +00:00
sbat: clang-format the whole thing.
Signed-off-by: Peter Jones <pjones@redhat.com>
This commit is contained in:
parent
4edb31fcfc
commit
0bc2aa4ca8
18
sbat.c
18
sbat.c
@ -23,8 +23,8 @@ get_sbat_field(CHAR8 *current, CHAR8 *end, const CHAR8 ** field, char delim)
|
||||
return offset + 1;
|
||||
}
|
||||
|
||||
EFI_STATUS parse_sbat_entry(CHAR8 **current, CHAR8 *end,
|
||||
struct sbat_entry **sbat_entry)
|
||||
EFI_STATUS
|
||||
parse_sbat_entry(CHAR8 **current, CHAR8 *end, struct sbat_entry **sbat_entry)
|
||||
{
|
||||
struct sbat_entry *entry = NULL;
|
||||
|
||||
@ -36,7 +36,8 @@ EFI_STATUS parse_sbat_entry(CHAR8 **current, CHAR8 *end,
|
||||
if (!entry->component_name)
|
||||
goto error;
|
||||
|
||||
*current = get_sbat_field(*current, end, &entry->component_generation,',');
|
||||
*current = get_sbat_field(*current, end, &entry->component_generation,
|
||||
',');
|
||||
if (!entry->component_generation)
|
||||
goto error;
|
||||
|
||||
@ -44,7 +45,8 @@ EFI_STATUS parse_sbat_entry(CHAR8 **current, CHAR8 *end,
|
||||
if (!entry->vendor_name)
|
||||
goto error;
|
||||
|
||||
*current = get_sbat_field(*current, end, &entry->vendor_package_name, ',');
|
||||
*current =
|
||||
get_sbat_field(*current, end, &entry->vendor_package_name, ',');
|
||||
if (!entry->vendor_package_name)
|
||||
goto error;
|
||||
|
||||
@ -65,8 +67,8 @@ error:
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
EFI_STATUS parse_sbat(char *sbat_base, size_t sbat_size, char *buffer,
|
||||
struct sbat *sbat)
|
||||
EFI_STATUS
|
||||
parse_sbat(char *sbat_base, size_t sbat_size, char *buffer, struct sbat *sbat)
|
||||
{
|
||||
CHAR8 *current = (CHAR8 *)sbat_base;
|
||||
CHAR8 *end = (CHAR8 *)sbat_base + sbat_size;
|
||||
@ -98,8 +100,8 @@ EFI_STATUS parse_sbat(char *sbat_base, size_t sbat_size, char *buffer,
|
||||
}
|
||||
|
||||
if (entry) {
|
||||
entries = ReallocatePool(sbat->entries,
|
||||
sbat->size * sizeof(entry),
|
||||
entries = ReallocatePool(
|
||||
sbat->entries, sbat->size * sizeof(entry),
|
||||
(sbat->size + 1) * sizeof(entry));
|
||||
if (!entries) {
|
||||
efi_status = EFI_OUT_OF_RESOURCES;
|
||||
|
Loading…
Reference in New Issue
Block a user