public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH] ShellPkg/HandleParsingLib: Correct format specifier for LoadedImage
@ 2017-02-14 21:54 Jeff Westfahl
  2017-02-14 22:40 ` Jim.Dailey
  0 siblings, 1 reply; 10+ messages in thread
From: Jeff Westfahl @ 2017-02-14 21:54 UTC (permalink / raw)
  To: edk2-devel

The format specifier for the LoadOptions field of the LoadedImage protocol
is "%s". However, the data in LoadOptions is often generic binary data. A
format specifier of "%x" is more appropriate for this field.

Using "dh -v" with format specifier "%s" on BIOS images based on EDK II
source before commit 891d844 can cause a crash.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Westfahl <jeff.westfahl@ni.com>
---
 ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni
index 0d51627c5f..273a4201bc 100644
--- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni
+++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni
@@ -354,7 +354,7 @@
                                                   "     DeviceHandle..: %%H%x%%N\r\n"
                                                   "     FilePath......: %%H%x%%N\r\n"
                                                   "     OptionsSize...: %%H%x%%N\r\n"
-                                                  "     LoadOptions...: %%H%s%%N\r\n"
+                                                  "     LoadOptions...: %%H%x%%N\r\n"
                                                   "     ImageBase.....: %%H%x%%N\r\n"
                                                   "     ImageSize.....: %%H%Lx%%N\r\n"
                                                   "     CodeType......: %%H%s%%N\r\n"
-- 
2.11.0.windows.3



^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2017-02-17 18:15 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-14 21:54 [PATCH] ShellPkg/HandleParsingLib: Correct format specifier for LoadedImage Jeff Westfahl
2017-02-14 22:40 ` Jim.Dailey
2017-02-14 22:44   ` Jim.Dailey
2017-02-15 20:41     ` Jeff Westfahl
2017-02-17 16:54       ` Jeff Westfahl
2017-02-17 17:27         ` Carsey, Jaben
2017-02-17 17:35           ` Jim.Dailey
2017-02-17 17:37             ` Carsey, Jaben
2017-02-17 17:43               ` Jeff Westfahl
2017-02-17 18:12                 ` Jim.Dailey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox