From 2a9d43407bb7433a53dac487243b54102f94c902 Mon Sep 17 00:00:00 2001
From: Mark Spencer <markster@digium.com>
Date: Wed, 14 Jul 2004 07:48:47 +0000
Subject: [PATCH] Oops forgot one (bug #2038)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@3431 65c4cc65-6c06-0410-ace0-fbb531ad65f3
---
 apps/app_setcidname.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/apps/app_setcidname.c b/apps/app_setcidname.c
index c73af9a433..ee430911be 100755
--- a/apps/app_setcidname.c
+++ b/apps/app_setcidname.c
@@ -72,7 +72,7 @@ static int setcallerid_exec(struct ast_channel *chan, void *data)
 			strncpy(newcid, l, sizeof(newcid) - 1);
 		}
 	} else
-		strncpy(newcid, tmp, sizeof(newcid));
+		strncpy(newcid, tmp, sizeof(newcid) - 1);
 	ast_set_callerid(chan, !ast_strlen_zero(newcid) ? newcid : NULL, anitoo);
 	LOCAL_USER_REMOVE(u);
 	return res;
-- 
GitLab