diff --git a/Library/OcBootManagementLib/BootArguments.c b/Library/OcBootManagementLib/BootArguments.c index c48d96fd..c0b8c84a 100644 --- a/Library/OcBootManagementLib/BootArguments.c +++ b/Library/OcBootManagementLib/BootArguments.c @@ -262,7 +262,7 @@ OcCheckArgumentFromEnv ( } } - if (HasArgument) { + if (HasArgument && Value != NULL) { *Value = AllocateCopyPool (AsciiStrnSizeS (ArgValue, ArgValueLength), ArgValue); if (*Value == NULL) { return FALSE;