[Asterisk-code-review] app voicemail.c: Fix compiler warning with IMAP build. (asterisk[13])

Richard Mudgett asteriskteam at digium.com
Thu Oct 26 12:24:27 CDT 2017


Richard Mudgett has uploaded this change for review. ( https://gerrit.asterisk.org/6924


Change subject: app_voicemail.c: Fix compiler warning with IMAP build.
......................................................................

app_voicemail.c: Fix compiler warning with IMAP build.

ASTERISK-27181

Change-Id: Ic4468b49860bd7f67e922baf4c9e96828c184d17
---
M apps/app_voicemail.c
1 file changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/24/6924/1

diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c
index f954e27..d0e1763 100644
--- a/apps/app_voicemail.c
+++ b/apps/app_voicemail.c
@@ -8922,7 +8922,7 @@
 {
 	char *file, *filename;
 	char *attachment;
-	char arg[10];
+	char arg[11];
 	int i;
 	BODY* body;
 	int curr_mbox;
@@ -8958,7 +8958,7 @@
 		}
 		filename = strsep(&attachment, ".");
 		if (!strcmp(filename, file)) {
-			sprintf(arg, "%d", i + 1);
+			snprintf(arg, sizeof(arg), "%d", i + 1);
 			mail_setflag(vms->mailstream, arg, "\\DELETED");
 		}
 	}

-- 
To view, visit https://gerrit.asterisk.org/6924
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic4468b49860bd7f67e922baf4c9e96828c184d17
Gerrit-Change-Number: 6924
Gerrit-PatchSet: 1
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20171026/4703adb3/attachment.html>


More information about the asterisk-code-review mailing list