[edk2-devel] [PATCH V2 1/5] RedfishPkg: Correct variable type to prevent memory corruption
Minh Nguyen via groups.io
minhnguyen1=os.amperecomputing.com at groups.io
Thu May 4 04:19:41 UTC 2023
From: Vu Nguyen <vunguyen at os.amperecomputing.com>
Id will be casted by CoreOpenProtocol, declare this variable with a
wrong type might result in the corruption of other local variables.
Signed-off-by: Minh Nguyen <minhnguyen1 at os.amperecomputing.com>
Cc: Abner Chang <abner.chang at amd.com>
Cc: Igor Kulchytskyy <igork at ami.com>
Cc: Nick Ramirez <nramirez at nvidia.com>
Reviewed-by: Nickle Wang <nicklew at nvidia.com>
---
RedfishPkg/RedfishRestExDxe/RedfishRestExDriver.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/RedfishPkg/RedfishRestExDxe/RedfishRestExDriver.h b/RedfishPkg/RedfishRestExDxe/RedfishRestExDriver.h
index 4a9e9f7b81a4..6b94e5814c43 100644
--- a/RedfishPkg/RedfishRestExDxe/RedfishRestExDriver.h
+++ b/RedfishPkg/RedfishRestExDxe/RedfishRestExDriver.h
@@ -3,6 +3,7 @@
Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
(C) Copyright 2020 Hewlett Packard Enterprise Development LP<BR>
+ Copyright (c) 2023, Ampere Computing LLC. All rights reserved.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -84,7 +85,7 @@ struct _RESTEX_SERVICE {
//
EFI_HANDLE HttpChildHandle;
- UINT32 Id;
+ UINT32 *Id;
EFI_REST_EX_SERVICE_INFO RestExServiceInfo;
};
--
2.39.0
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#103949): https://edk2.groups.io/g/devel/message/103949
Mute This Topic: https://groups.io/mt/98678063/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-
More information about the edk2-devel-archive
mailing list