diff options
Diffstat (limited to 'libebl')
| -rw-r--r-- | libebl/ChangeLog | 9 | ||||
| -rw-r--r-- | libebl/eblobjnote.c | 4 | ||||
| -rw-r--r-- | libebl/eblobjnotetypename.c | 3 | ||||
| -rw-r--r-- | libebl/eblopenbackend.c | 2 |
4 files changed, 17 insertions, 1 deletions
diff --git a/libebl/ChangeLog b/libebl/ChangeLog index fff66b3e..2e31e75d 100644 --- a/libebl/ChangeLog +++ b/libebl/ChangeLog @@ -1,3 +1,12 @@ +2021-12-21 Luca Boccassi <[email protected]> + + * eblobjnote.c (ebl_object_note): Handle NT_FDO_PACKAGING_METADATA. + * eblobjnotetypename.c (ebl_object_note_type_name): Likewise. + +2021-09-06 Dmitry V. Levin <[email protected]> + + * eblopenbackend.c (openbackend): Remove cast of calloc return value. + 2021-04-19 Martin Liska <[email protected]> * eblobjnotetypename.c (ebl_object_note_type_name): Use startswith. diff --git a/libebl/eblobjnote.c b/libebl/eblobjnote.c index 36efe275..5a7c5c62 100644 --- a/libebl/eblobjnote.c +++ b/libebl/eblobjnote.c @@ -288,6 +288,10 @@ ebl_object_note (Ebl *ebl, uint32_t namesz, const char *name, uint32_t type, if (descsz == 0 && type == NT_VERSION) return; + if (strcmp ("FDO", name) == 0 && type == NT_FDO_PACKAGING_METADATA + && descsz > 0 && desc[descsz - 1] == '\0') + printf(" Packaging Metadata: %.*s\n", (int) descsz, desc); + /* Everything else should have the "GNU" owner name. */ if (strcmp ("GNU", name) != 0) return; diff --git a/libebl/eblobjnotetypename.c b/libebl/eblobjnotetypename.c index 4662906d..473a1f2f 100644 --- a/libebl/eblobjnotetypename.c +++ b/libebl/eblobjnotetypename.c @@ -101,6 +101,9 @@ ebl_object_note_type_name (Ebl *ebl, const char *name, uint32_t type, return buf; } + if (strcmp (name, "FDO") == 0 && type == NT_FDO_PACKAGING_METADATA) + return "FDO_PACKAGING_METADATA"; + if (strcmp (name, "GNU") != 0) { /* NT_VERSION is special, all data is in the name. */ diff --git a/libebl/eblopenbackend.c b/libebl/eblopenbackend.c index 2ff86416..831b865d 100644 --- a/libebl/eblopenbackend.c +++ b/libebl/eblopenbackend.c @@ -267,7 +267,7 @@ openbackend (Elf *elf, const char *emulation, GElf_Half machine) /* First allocate the data structure for the result. We do this here since this assures that the structure is always large enough. */ - result = (Ebl *) calloc (1, sizeof (Ebl)); + result = calloc (1, sizeof (Ebl)); if (result == NULL) { // XXX uncomment |
