]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
uefi: drop redundant local variable
authorLennart Poettering <lennart@poettering.net>
Mon, 24 Jun 2024 15:38:29 +0000 (17:38 +0200)
committerLennart Poettering <lennart@poettering.net>
Mon, 24 Jun 2024 20:43:45 +0000 (22:43 +0200)
src/boot/efi/measure.c

index 27c382c170892ce3188af76202f3ae4997d919fb..24cb60e7a315278654a7ee7f8eeb3320f2f0cd8b 100644 (file)
@@ -288,7 +288,6 @@ EFI_STATUS tpm_log_ipl_event_ascii(uint32_t pcrindex, EFI_PHYSICAL_ADDRESS buffe
 }
 
 EFI_STATUS tpm_log_load_options(const char16_t *load_options, bool *ret_measured) {
-        bool measured = false;
         EFI_STATUS err;
 
         /* Measures a load options string into the TPM2, i.e. the kernel command line */
@@ -298,16 +297,13 @@ EFI_STATUS tpm_log_load_options(const char16_t *load_options, bool *ret_measured
                         POINTER_TO_PHYSICAL_ADDRESS(load_options),
                         strsize16(load_options),
                         load_options,
-                        &measured);
+                        ret_measured);
         if (err != EFI_SUCCESS)
                 return log_error_status(
                                 err,
                                 "Unable to add load options (i.e. kernel command) line measurement to PCR %i: %m",
                                 TPM2_PCR_KERNEL_CONFIG);
 
-        if (ret_measured)
-                *ret_measured = measured;
-
         return EFI_SUCCESS;
 }