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

Jenkins2 asteriskteam at digium.com
Fri Oct 27 08:28:43 CDT 2017


Jenkins2 has submitted this change and it was merged. ( 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(-)

Approvals:
  Corey Farrell: Looks good to me, but someone else must approve
  Joshua Colp: Looks good to me, approved
  Jenkins2: Approved for Submit



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: merged
Gerrit-Change-Id: Ic4468b49860bd7f67e922baf4c9e96828c184d17
Gerrit-Change-Number: 6924
Gerrit-PatchSet: 1
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20171027/d3142857/attachment.html>


More information about the asterisk-code-review mailing list