diff options
Diffstat (limited to '0041-Implement-Print-L-p-ptr.patch')
-rw-r--r-- | 0041-Implement-Print-L-p-ptr.patch | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/0041-Implement-Print-L-p-ptr.patch b/0041-Implement-Print-L-p-ptr.patch new file mode 100644 index 0000000..d6ff3eb --- /dev/null +++ b/0041-Implement-Print-L-p-ptr.patch @@ -0,0 +1,35 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Peter Jones <pjones@redhat.com> +Date: Mon, 18 Nov 2019 13:06:23 -0500 +Subject: [PATCH] Implement Print(L"%p", ptr); + +Signed-off-by: Peter Jones <pjones@redhat.com> +--- + lib/print.c | 14 ++++++++++++++ + 1 file changed, 14 insertions(+) + +diff --git a/lib/print.c b/lib/print.c +index 0b823481347..8fdba6ee166 100644 +--- a/lib/print.c ++++ b/lib/print.c +@@ -1181,6 +1181,20 @@ Returns: + PSETATTR(ps, ps->AttrNorm); + break; + ++ case 'p': ++ Item.Width = sizeof(void *) == (8 ? 16 : 8) + 2; ++ Item.Pad = '0'; ++ Item.Scratch[0] = ' '; ++ Item.Scratch[1] = ' '; ++ ValueToHex ( ++ Item.Scratch+2, ++ Item.Long ? va_arg(ps->args, UINT64) : va_arg(ps->args, UINT32) ++ ); ++ Item.Scratch[0] = '0'; ++ Item.Scratch[1] = 'x'; ++ Item.Item.pw = Item.Scratch; ++ break; ++ + case 'r': + StatusToString (Item.Scratch, va_arg(ps->args, EFI_STATUS)); + Item.Item.pw = Item.Scratch; |