]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Application/CapsuleApp/CapsuleApp.c
MdeModulePkg CapsuleApp: Refine -D option help information
[mirror_edk2.git] / MdeModulePkg / Application / CapsuleApp / CapsuleApp.c
index 3a1a0a1cb2e61b69273e907bbb996162c2419de3..e943038a0d00dcee4605961ced7e77609d9404cd 100644 (file)
@@ -742,13 +742,13 @@ PrintUsage (
   Print(L"       which is defined in UEFI specification.\n");\r
   Print(L"  -P:  Dump UEFI FMP protocol info.\n");\r
   Print(L"  -E:  Dump UEFI ESRT table info.\n");\r
-  Print(L"  -G:  Convert a BMP file to be a UX capsule,\n");\r
+  Print(L"  -G:  Convert a BMP file to be an UX capsule,\n");\r
   Print(L"       according to Windows Firmware Update document\n");\r
   Print(L"  -N:  Append a Capsule Header to an existing capsule image,\n");\r
   Print(L"       according to Windows Firmware Update document\n");\r
   Print(L"  -O:  Output new Capsule file name\n");\r
-  Print(L"  -D:  Dump Capsule image header information and FMP header information,\n");\r
-  Print(L"       if it is an FMP capsule.\n");\r
+  Print(L"  -D:  Dump Capsule image header information, image payload information if it is an UX capsule\n");\r
+  Print(L"       and FMP header information if it is a FMP capsule.\n");\r
 }\r
 \r
 /**\r
@@ -792,6 +792,10 @@ UefiMain (
     return EFI_INVALID_PARAMETER;\r
   }\r
   if (StrCmp(Argv[1], L"-D") == 0) {\r
+    if (Argc < 3) {\r
+      Print(L"CapsuleApp: NO input capsule name.\n");\r
+      return EFI_INVALID_PARAMETER;\r
+    }\r
     Status = DumpCapsule(Argv[2]);\r
     return Status;\r
   }\r