[Asterisk-code-review] app_osplookup.c: Avoid a format truncation. (asterisk[master])

Alexander Traud asteriskteam at digium.com
Sat Apr 4 04:28:00 CDT 2020


Alexander Traud has uploaded this change for review. ( https://gerrit.asterisk.org/c/asterisk/+/14086 )


Change subject: app_osplookup.c: Avoid a format truncation.
......................................................................

app_osplookup.c: Avoid a format truncation.

ASTERISK-28804

Change-Id: Ie54c8241ff0cc653910539c2db00ff2a4869750b
---
M apps/app_osplookup.c
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/86/14086/1

diff --git a/apps/app_osplookup.c b/apps/app_osplookup.c
index 78f573a..c8d14be 100644
--- a/apps/app_osplookup.c
+++ b/apps/app_osplookup.c
@@ -994,7 +994,7 @@
 	unsigned int destsize)
 {
 	struct in_addr inp;
-	char buffer[OSP_SIZE_NORSTR];
+	char buffer[OSP_SIZE_NORSTR - strlen("[]:")];
 	char* port;
 
 	if ((dest != NULL) && (destsize > 0)) {

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

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Change-Id: Ie54c8241ff0cc653910539c2db00ff2a4869750b
Gerrit-Change-Number: 14086
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Traud <pabstraud at compuserve.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20200404/6d8823f7/attachment-0001.html>


More information about the asterisk-code-review mailing list