mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 17:25:35 +03:00
DCE_KMD: Fix TOP 25 CWE Rule
- This patch fixes the following violations OVERRUN - 1 (24138320) - Added checks to validate boundries Rule: OVERRUN Rule Description: Out-of-bounds access to a buffer JIRA TDS-15862 Change-Id: I4df6c7124da19143eb0d9b8027df28fccdff0b75 Signed-off-by: saranyad <saranyad@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3305934 Reviewed-by: svcacv <svcacv@nvidia.com> Reviewed-by: Vinod Gopalakrishnakurup <vinodg@nvidia.com> GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
@@ -318,7 +318,7 @@ int dce_client_init(struct tegra_dce *d)
|
|||||||
}
|
}
|
||||||
|
|
||||||
fail_work_init:
|
fail_work_init:
|
||||||
if (ret) {
|
if (ret && (i > 0)) {
|
||||||
uint8_t j = 0;
|
uint8_t j = 0;
|
||||||
|
|
||||||
for (j = i - 1; j >= 0; j--) {
|
for (j = i - 1; j >= 0; j--) {
|
||||||
|
|||||||
Reference in New Issue
Block a user