[PATCH] uefi: eufidump: fix infinite recursion on unknown end terminator
Colin King
colin.king at canonical.com
Fri Feb 10 11:14:29 UTC 2012
From: Colin Ian King <colin.king at canonical.com>
Signed-off-by: Colin Ian King <colin.king at canonical.com>
---
src/uefi/uefidump/uefidump.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/uefi/uefidump/uefidump.c b/src/uefi/uefidump/uefidump.c
index 6c5fbd4..9a12dc7 100644
--- a/src/uefi/uefidump/uefidump.c
+++ b/src/uefi/uefidump/uefidump.c
@@ -64,14 +64,14 @@ static char *uefidump_vprintf(char *str, const char *fmt, ...)
static char *uefidump_build_dev_path(char *path, fwts_uefi_dev_path *dev_path)
{
switch (dev_path->type & 0x7f) {
+printf("%x %s\n", dev_path->type, path);
case FWTS_UEFI_END_DEV_PATH_TYPE:
switch (dev_path->subtype) {
case FWTS_UEFI_END_ENTIRE_DEV_PATH_SUBTYPE:
case FWTS_UEFI_END_THIS_DEV_PATH_SUBTYPE:
break;
default:
- path = uefidump_vprintf(path, "\\Unknown-End(0x%x)", (unsigned int) dev_path->subtype);
- break;
+ return uefidump_vprintf(path, "\\Unknown-End(0x%x)", (unsigned int) dev_path->subtype);
}
break;
case FWTS_UEFI_HARDWARE_DEV_PATH_TYPE:
--
1.7.9
More information about the fwts-devel
mailing list