summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Jones <pjones@redhat.com>2025-03-12 13:56:54 -0400
committerPeter Jones <pjones@redhat.com>2025-03-14 11:05:05 -0400
commit76fab7bd7e61e080ac8ae28450cae6f533159086 (patch)
treeacbf5cfd5321de660fa6e920caec30b22ad4d46d
parentd45c610ba558c1b1673ff94590b71a156dd2fd3c (diff)
downloadefi-boot-shim-76fab7bd7e61e080ac8ae28450cae6f533159086.tar.gz
efi-boot-shim-76fab7bd7e61e080ac8ae28450cae6f533159086.zip
generate_sbat_var_defs: run clang-format on readfile()
Signed-off-by: Peter Jones <pjones@redhat.com>
-rw-r--r--generate_sbat_var_defs.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/generate_sbat_var_defs.c b/generate_sbat_var_defs.c
index e29fcbd7..3ae62eba 100644
--- a/generate_sbat_var_defs.c
+++ b/generate_sbat_var_defs.c
@@ -41,8 +41,8 @@ readfile(char *SbatLevel_Variable)
while (fgets(line, sizeof(line), varfilep) != NULL) {
if (sscanf(line, "sbat,1,%d\n", &date) && strlen(line) == 18) {
- revlistentry =
- (sbat_revocation *)malloc(sizeof(sbat_revocation));
+ revlistentry = (sbat_revocation *)malloc(
+ sizeof(sbat_revocation));
if (revlistentry == NULL)
return -1;
if (revlisthead == NULL)
@@ -55,21 +55,21 @@ readfile(char *SbatLevel_Variable)
revlistentry->date = date;
while (line[0] != '\n' &&
fgets(line, sizeof(line), varfilep) != NULL) {
- revlistentry->revocations =
- (char *)realloc(revlistentry->revocations,
- revocationsp +
- strlen(line) + 1);
- if (revlistentry->revocations == NULL)
- return -1;
- if (strlen(line) > 1) {
- line[strlen(line) -1] = 0;
- sprintf(revlistentry->revocations
- + revocationsp, "%s\\n", line);
- revocationsp = revocationsp + strlen(line) + 2;
- }
+ revlistentry->revocations = (char *)realloc(
+ revlistentry->revocations,
+ revocationsp + strlen(line) + 1);
+ if (revlistentry->revocations == NULL)
+ return -1;
+ if (strlen(line) > 1) {
+ line[strlen(line) - 1] = 0;
+ sprintf(revlistentry->revocations +
+ revocationsp,
+ "%s\\n", line);
+ revocationsp =
+ revocationsp + strlen(line) + 2;
+ }
}
revocationsp = 0;
-
}
}