FreeBSD Bugzilla – Attachment 205172 Details for
Bug 238654
sysutils/shim: Unbreak build with GCC 9
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
shim.diff
shim.diff (text/plain), 2.77 KB, created by
Tobias Kortkamp
on 2019-06-17 11:18:52 UTC
(
hide
)
Description:
shim.diff
Filename:
MIME Type:
Creator:
Tobias Kortkamp
Created:
2019-06-17 11:18:52 UTC
Size:
2.77 KB
patch
obsolete
>Index: sysutils/shim/Makefile >=================================================================== >--- sysutils/shim/Makefile (revision 504394) >+++ sysutils/shim/Makefile (working copy) >@@ -3,7 +3,7 @@ > > PORTNAME= shim > PORTVERSION= 0.9 >-PORTREVISION= 2 >+PORTREVISION= 3 > CATEGORIES= sysutils > > MAINTAINER= egypcio@FreeBSD.org >Index: sysutils/shim/files/patch-MokManager.c >=================================================================== >--- sysutils/shim/files/patch-MokManager.c (revision 504394) >+++ sysutils/shim/files/patch-MokManager.c (working copy) >@@ -1,6 +1,6 @@ > --- MokManager.c.orig 2015-06-30 18:20:12 UTC > +++ MokManager.c >-@@ -588,11 +588,11 @@ static void show_mok_info (EFI_GUID Type >+@@ -588,11 +588,11 @@ static void show_mok_info (EFI_GUID Type, void *Mok, U > > static EFI_STATUS list_keys (void *KeyList, UINTN KeyListSize, CHAR16 *title) > { >@@ -14,3 +14,52 @@ > > if (KeyListSize < (sizeof(EFI_SIGNATURE_LIST) + > sizeof(EFI_SIGNATURE_DATA))) { >+@@ -1037,7 +1037,8 @@ static EFI_STATUS write_back_mok_list (MokListNode *li >+ continue; >+ >+ DataSize += sizeof(EFI_SIGNATURE_LIST); >+- if (CompareGuid(&(list[i].Type), &CertType) == 0) >++ if (CompareMem(&(list[i].Type), &CertType, >++ sizeof(EFI_GUID)) == 0) >+ DataSize += sizeof(EFI_GUID); >+ DataSize += list[i].MokSize; >+ } >+@@ -1059,7 +1060,8 @@ static EFI_STATUS write_back_mok_list (MokListNode *li >+ CertList->SignatureType = list[i].Type; >+ CertList->SignatureHeaderSize = 0; >+ >+- if (CompareGuid(&(list[i].Type), &CertType) == 0) { >++ if (CompareMem(&(list[i].Type), &CertType, >++ sizeof(EFI_GUID)) == 0) { >+ CertList->SignatureListSize = list[i].MokSize + >+ sizeof(EFI_SIGNATURE_LIST) + >+ sizeof(EFI_GUID); >+@@ -1100,7 +1102,8 @@ static void delete_cert (void *key, UINT32 key_size, >+ int i; >+ >+ for (i = 0; i < mok_num; i++) { >+- if (CompareGuid(&(mok[i].Type), &CertType) != 0) >++ if (CompareMem(&(mok[i].Type), &CertType, >++ sizeof(EFI_GUID)) != 0) >+ continue; >+ >+ if (mok[i].MokSize == key_size && >+@@ -1151,7 +1154,7 @@ static void delete_hash_in_list (EFI_GUID Type, UINT8 >+ sig_size = hash_size + sizeof(EFI_GUID); >+ >+ for (i = 0; i < mok_num; i++) { >+- if ((CompareGuid(&(mok[i].Type), &Type) != 0) || >++ if ((CompareMem(&(mok[i].Type), &Type, sizeof(EFI_GUID)) != 0) || >+ (mok[i].MokSize < sig_size)) >+ continue; >+ >+@@ -1322,7 +1325,8 @@ static EFI_STATUS delete_keys (void *MokDel, UINTN Mok >+ >+ /* Search and destroy */ >+ for (i = 0; i < del_num; i++) { >+- if (CompareGuid(&(del_key[i].Type), &CertType) == 0) { >++ if (CompareMem(&(del_key[i].Type), &CertType, >++ sizeof(EFI_GUID)) == 0) { >+ delete_cert(del_key[i].Mok, del_key[i].MokSize, >+ mok, mok_num); >+ } else if (is_sha2_hash(del_key[i].Type)) {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
tobik
:
maintainer-approval?
(
egypcio
)
Actions:
View
|
Diff
Attachments on
bug 238654
: 205172