Date: Fri, 3 Mar 2017 20:23:23 +0000 (UTC) From: Warner Losh <imp@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r314623 - head/lib/libefivar Message-ID: <201703032023.v23KNNm6063451@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: imp Date: Fri Mar 3 20:23:23 2017 New Revision: 314623 URL: https://svnweb.freebsd.org/changeset/base/314623 Log: Make sure guid table is compiled before we use it. Sponsored by: Netflix Modified: head/lib/libefivar/efivar.c Modified: head/lib/libefivar/efivar.c ============================================================================== --- head/lib/libefivar/efivar.c Fri Mar 3 20:23:21 2017 (r314622) +++ head/lib/libefivar/efivar.c Fri Mar 3 20:23:23 2017 (r314623) @@ -301,6 +301,7 @@ efi_guid_to_name(efi_guid_t *guid, char size_t i; uint32_t status; + efi_guid_tbl_compile(); for (i = 0; i < nitems(guid_tbl); i++) { if (uuid_equal(guid, &guid_tbl[i].guid, &status)) { *name = strdup(guid_tbl[i].name); @@ -337,6 +338,7 @@ efi_name_to_guid(const char *name, efi_g { size_t i; + efi_guid_tbl_compile(); for (i = 0; i < nitems(guid_tbl); i++) { if (strcmp(name, guid_tbl[i].name) == 0) { *guid = guid_tbl[i].guid;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201703032023.v23KNNm6063451>