Change in ...osmocom-bb[master]: virtphy: Fix array out of bounds access in getL1ctlPrimName()

laforge gerrit-no-reply at lists.osmocom.org
Sun Jul 21 10:29:34 UTC 2019


laforge has submitted this change and it was merged. ( https://gerrit.osmocom.org/c/osmocom-bb/+/14848 )

Change subject: virtphy: Fix array out of bounds access in getL1ctlPrimName()
......................................................................

virtphy: Fix array out of bounds access in getL1ctlPrimName()

Closes: CID#198573
Change-Id: I6504a7ffcf961d3162e6ab2ec8f5f2016ef12cde
---
M src/host/virt_phy/src/logging.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Jenkins Builder: Verified
  fixeria: Looks good to me, approved



diff --git a/src/host/virt_phy/src/logging.c b/src/host/virt_phy/src/logging.c
index a3e63bc..7e4e79b 100644
--- a/src/host/virt_phy/src/logging.c
+++ b/src/host/virt_phy/src/logging.c
@@ -128,7 +128,7 @@
 
 const char *getL1ctlPrimName(uint8_t type)
 {
-	if (type <= ARRAY_SIZE(l1ctlPrimNames))
+	if (type < ARRAY_SIZE(l1ctlPrimNames))
 		return l1ctlPrimNames[type];
 	else
 		return "Unknwon Primitive";

-- 
To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/14848
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmocom-bb
Gerrit-Branch: master
Gerrit-Change-Id: I6504a7ffcf961d3162e6ab2ec8f5f2016ef12cde
Gerrit-Change-Number: 14848
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <axilirator at gmail.com>
Gerrit-Reviewer: laforge <laforge at gnumonks.org>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190721/5b5bbe41/attachment.html>


More information about the gerrit-log mailing list