Skip to content

Commit

Permalink
integrity: Fix sparse warnings in keyring_handler
Browse files Browse the repository at this point in the history
Fix the following sparse warnings:

  CHECK   security/integrity/platform_certs/keyring_handler.c
security/integrity/platform_certs/keyring_handler.c:76:16: warning: Using plain integer as NULL pointer
security/integrity/platform_certs/keyring_handler.c:91:16: warning: Using plain integer as NULL pointer
security/integrity/platform_certs/keyring_handler.c:106:16: warning: Using plain integer as NULL pointer

Signed-off-by: Stefan Berger <[email protected]>
Signed-off-by: Mimi Zohar <[email protected]>
  • Loading branch information
stefanberger authored and mimizohar committed May 16, 2022
1 parent 4c41186 commit 048ae41
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions security/integrity/platform_certs/keyring_handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ __init efi_element_handler_t get_handler_for_db(const efi_guid_t *sig_type)
{
if (efi_guidcmp(*sig_type, efi_cert_x509_guid) == 0)
return add_to_platform_keyring;
return 0;
return NULL;
}

/*
Expand All @@ -88,7 +88,7 @@ __init efi_element_handler_t get_handler_for_mok(const efi_guid_t *sig_type)
else
return add_to_platform_keyring;
}
return 0;
return NULL;
}

/*
Expand All @@ -103,5 +103,5 @@ __init efi_element_handler_t get_handler_for_dbx(const efi_guid_t *sig_type)
return uefi_blacklist_binary;
if (efi_guidcmp(*sig_type, efi_cert_x509_guid) == 0)
return uefi_revocation_list_x509;
return 0;
return NULL;
}

0 comments on commit 048ae41

Please sign in to comment.