summaryrefslogtreecommitdiff
path: root/ArmPkg/Library/BdsLib/BdsHelper.c
diff options
context:
space:
mode:
Diffstat (limited to 'ArmPkg/Library/BdsLib/BdsHelper.c')
-rw-r--r--ArmPkg/Library/BdsLib/BdsHelper.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ArmPkg/Library/BdsLib/BdsHelper.c b/ArmPkg/Library/BdsLib/BdsHelper.c
index fb2ac9b806..1d4aa35728 100644
--- a/ArmPkg/Library/BdsLib/BdsHelper.c
+++ b/ArmPkg/Library/BdsLib/BdsHelper.c
@@ -331,7 +331,7 @@ GetEnvironmentVariable (
*Size,
DefaultValue
);
- *Value = DefaultValue;
+ *Value = AllocateCopyPool (*Size, DefaultValue);
} else {
return EFI_NOT_FOUND;
}
@@ -352,7 +352,7 @@ GetEnvironmentVariable (
*Size = VariableSize;
}
} else {
- *Value = DefaultValue;
+ *Value = AllocateCopyPool (*Size, DefaultValue);
return Status;
}